Hopefully fixed access to uninitialized settings when pausing

This commit is contained in:
Yair Morgenstern 2020-02-22 21:49:08 +02:00
parent aeee5e22eb
commit da9c65d288

View File

@ -57,8 +57,8 @@ class AndroidLauncher : AndroidApplication() {
override fun onPause() {
if (UncivGame.Companion.isCurrentInitialized()
&& UncivGame.Current.settings.multiplayerTurnCheckerEnabled
&& UncivGame.Current.isGameInfoInitialized()
&& UncivGame.Current.settings.multiplayerTurnCheckerEnabled
&& UncivGame.Current.gameInfo.gameParameters.isOnlineMultiplayer) {
MultiplayerTurnCheckWorker.startTurnChecker(applicationContext, UncivGame.Current.gameInfo, UncivGame.Current.settings)
}