check if the current week fragment is really added to the activity

This commit is contained in:
tibbi 2017-07-17 23:17:31 +02:00
parent 70cc8a0781
commit 55bfaf3c12
1 changed files with 1 additions and 1 deletions

View File

@ -223,7 +223,7 @@ class WeekFragment : Fragment(), WeeklyCalendar {
return
activity.runOnUiThread {
if (context != null)
if (context != null && isAdded)
addEvents()
}
}