diff --git a/app/src/main/kotlin/com/simplemobiletools/calendar/activities/MainActivity.kt b/app/src/main/kotlin/com/simplemobiletools/calendar/activities/MainActivity.kt index e737cdb53..ac1e1f215 100644 --- a/app/src/main/kotlin/com/simplemobiletools/calendar/activities/MainActivity.kt +++ b/app/src/main/kotlin/com/simplemobiletools/calendar/activities/MainActivity.kt @@ -578,8 +578,11 @@ class MainActivity : SimpleActivity(), RefreshRecyclerViewListener { val bundle = Bundle() bundle.putString(DAY_CODE, Formatter.getDayCodeFromDateTime(dateTime)) fragment.arguments = bundle - supportFragmentManager.beginTransaction().add(R.id.fragments_holder, fragment).commitNow() - supportActionBar?.setDisplayHomeAsUpEnabled(true) + try { + supportFragmentManager.beginTransaction().add(R.id.fragments_holder, fragment).commitNow() + supportActionBar?.setDisplayHomeAsUpEnabled(true) + } catch (e: Exception) { + } } private fun getThisWeekDateTime(): String {