fix(snooze): preserve original alarm categories, sound and label on snooze - #21
Merged
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Owner
Author
|
I reviewed this PR and found one functional issue to fix before merge: In lib/screens/alarm_ring/alarm_ring_screen.dart _snooze(), the snooze payload now includes difficulty, categories, sound, and label, but still omits alarmId. For one-shot alarms, dismissing from the snoozed ring screen depends on alarmId so _disableAlarmIfOneShot() can disable the original alarm; without it, the original alarm may stay enabled and fire again later. Suggested fix: include alarmId in the snooze payload when available and keep forwarding it through router extras (already supported). |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
categories,sound, andlabelfrom the original alarm into the snooze notification payload in_snooze()(alarm_ring_screen.dart)labelfield toAlarmRingScreenso the snooze notification title reflects the original alarm labellabelfrom notification payload in_handleNotificationPayload(main.dart) and forward it toAlarmRingScreenvia the router extraslabelin the scheduled alarm payload inAlarmService.scheduleAlarmso it is available end-to-endCloses #11
Acceptance Criteria Verification
categoriesas the originalsoundas the originallabelas the originalflutter analyze --fatal-infosexits 0