prevent NPE

This commit is contained in:
Milos Kozak 2022-04-06 14:32:31 +02:00
parent 75032c571f
commit ceeaf458d9
2 changed files with 2 additions and 3 deletions

View file

@ -308,6 +308,7 @@ class OverviewFragment : DaggerFragment(), View.OnClickListener, OnLongClickList
fun refreshAll() { fun refreshAll() {
runOnUiThread { runOnUiThread {
_binding ?: return@runOnUiThread
updateBg() updateBg()
updateTime() updateTime()
updateProfile() updateProfile()

View file

@ -1,11 +1,9 @@
package info.nightscout.androidaps.skins package info.nightscout.androidaps.skins
import android.util.DisplayMetrics import android.util.DisplayMetrics
import android.view.View
import android.widget.LinearLayout
import info.nightscout.androidaps.interfaces.Config
import info.nightscout.androidaps.R import info.nightscout.androidaps.R
import info.nightscout.androidaps.databinding.OverviewFragmentBinding import info.nightscout.androidaps.databinding.OverviewFragmentBinding
import info.nightscout.androidaps.interfaces.Config
import javax.inject.Inject import javax.inject.Inject
import javax.inject.Singleton import javax.inject.Singleton