mirror of
https://github.com/MBombeck/HealthLog.git
synced 2026-11-09 04:50:59 +00:00
`medication.clientManaged` and `measurementReminder.clientManaged` mean the iOS client schedules the reminder locally, so the server should not push it. That is what the OpenAPI description, the settings copy and the iOS contract all say. What the crons did was skip the dispatch entirely, so a user who flipped the switch also lost Telegram, ntfy, webhook, email and Web Push — channels they may well read on a desktop while the phone holding the local schedule sits in a drawer. Move the gate into the dispatcher's channel loop, where it applies to APNs and nothing else. The skip is not counted as an attempt, so `dispatched` keeps meaning "something reached the user", and it stays countable: the same wide-event keys the crons emitted are emitted here, plus a `skipped` row in the push-attempt ledger. The Vorsorge path is the sharper half. It suppressed every channel and then advanced `nextDueAt`, which dropped the reminder out of the preventive-care card and out of the daily digest: a reminder that never reached anyone was recorded as handled. The advance now happens only where it always belonged, after a dispatch that a channel actually delivered. When nothing delivers, the reminder stays overdue and visible.