Skip to content

Commit

Permalink
Merge pull request #16 from kirasok/snooze
Browse files Browse the repository at this point in the history
feat(ui): implement snooze
  • Loading branch information
kirasok authored Apr 3, 2024
2 parents 91e72c8 + 9247995 commit 6df42e3
Showing 1 changed file with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,11 @@ class AlarmService : Service(), MediaPlayer.OnPreparedListener, MediaPlayer.OnEr
onDestroy()
}

AlarmAction.SNOOZE -> onDestroy() // TODO: implement snooze
AlarmAction.SNOOZE -> {
runBlocking { useCases.insertAlarm(alarm.copy(timestamp = alarm.timestamp.plusMinutes(5))) }
onDestroy()
}

null -> throw IllegalStateException("Alarm action can't be null")
}
}
Expand Down

0 comments on commit 6df42e3

Please sign in to comment.