Fix IllegalStateException

This commit is contained in:
Mygod
2018-02-17 14:24:09 -08:00
parent ae4d61d6c4
commit 0cf864392e

View File

@@ -44,5 +44,5 @@ class MainActivity : AppCompatActivity(), BottomNavigationView.OnNavigationItemS
}
private fun displayFragment(fragment: Fragment) =
supportFragmentManager.beginTransaction().replace(R.id.fragmentHolder, fragment).commit()
supportFragmentManager.beginTransaction().replace(R.id.fragmentHolder, fragment).commitAllowingStateLoss()
}