Conversation
updateSchedules now takes a `days` parameter specifying which days to modify. Callers pass their specific days: - SmartCurveView: passes scheduleManager.selectedDays - ScheduleScreen (clear): passes scheduleManager.selectedDays - ScheduleManager: passes [selectedDay] for single-day edits Previously, updateSchedules iterated DayOfWeek.allCases regardless of which days were actually modified, causing a Monday-only change to delete and recreate entries for all 7 days. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
|
Caution Review failedPull request was closed or merged during review 📝 WalkthroughWalkthroughThe Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~12 minutes Possibly related PRs
Poem
🚥 Pre-merge checks | ✅ 2 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (2 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
📝 Coding Plan
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
🎉 This PR is included in version 1.0.0 🎉 The release is available on GitHub release Your semantic-release bot 📦🚀 |
Summary
Selecting Monday and applying a schedule was modifying all 7 days. Now only the selected days are updated.
Root cause
updateSchedulesiteratedDayOfWeek.allCasesregardless of which days the caller actually modified. A Monday-only edit would delete and recreate entries for every day of the week.Fix
Added
days: Set<DayOfWeek>?parameter toupdateSchedules. All callers now pass their specific days:scheduleManager.selectedDays(multi-select)scheduleManager.selectedDays(multi-select)[selectedDay]When
daysisnil(default), all days are updated (backward compatible).Test plan
🤖 Generated with Claude Code
Summary by CodeRabbit
Improvements