fix wear os build

This commit is contained in:
Lucas Lima 2020-03-18 00:30:28 -03:00
parent 166efb5c77
commit 518971615f
No known key found for this signature in database
GPG key ID: C5EEF4C30BFBF8D7
3 changed files with 4 additions and 4 deletions

View file

@ -387,8 +387,8 @@ class GameActivity : DaggerAppCompatActivity() {
val score = currentGameStatus.score
EndGameDialogFragment.newInstance(
victory,
score.rightMines,
score.totalMines,
score?.rightMines ?: 0,
score?.totalMines ?: 0,
currentGameStatus.time
).apply {
showAllowingStateLoss(supportFragmentManager, EndGameDialogFragment.TAG)

View file

@ -51,7 +51,7 @@ class EndGameDialogFragment : DaggerAppCompatDialogFragment() {
time = getLong(DIALOG_TIME)
rightMines = getInt(DIALOG_RIGHT_MINES)
totalMines = getInt(DIALOG_TOTAL_MINES)
hasValidData = true
hasValidData = (totalMines > 0)
}
}

View file

@ -7,6 +7,6 @@ sealed class Status {
class Over(
val time: Long = 0L,
val score: Score
val score: Score? = null
) : Status()
}