check if the current week fragment is really added to the activity
This commit is contained in:
parent
70cc8a0781
commit
55bfaf3c12
|
@ -223,7 +223,7 @@ class WeekFragment : Fragment(), WeeklyCalendar {
|
|||
return
|
||||
|
||||
activity.runOnUiThread {
|
||||
if (context != null)
|
||||
if (context != null && isAdded)
|
||||
addEvents()
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue