ultimate_alarm_clock
ultimate_alarm_clock copied to clipboard
Fix: AddOrUpdateAlarmController initializing ahead of time causing multiple bugsArchitectural change
Description
AddOrUpdateAlarmController is initialized with bottomNavigationBarBindings instead of the AddOrUpdateAlarmView, due to a dependency issue with InputTimeController. It depends on both AddOrUpdateAlarmController and TimerController, and gets initialized in the timer view, causing these controllers to be initialized when the bottom navigation bar is created.
Proposed Changes
I have decomposed InputTimeController into two controllers named AlarmInputTimeController and TimerInputTimeController, each consisting of their independent logic. By refactoring in this way, the AddOrUpdateAlarmController need not be initialized with bottomNavigationBarBindings; instead, it can be initialized with AddOrUpdateAlarmView.
Fixes #549
Checklist
- [ ] Tests have been added or updated to cover the changes
- [ ] Documentation has been updated to reflect the changes
- [x] Code follows the established coding style guidelines
- [ ] All tests are passing