mirror of
https://github.com/MBombeck/HealthLog.git
synced 2026-11-19 00:12:18 +00:00
Existing WHOOP Workout rows still carry whatever the pre-fix write path stored — a whoop_sport_<id> placeholder or WHOOP's raw sport_name — so the sport-map fix only corrects new syncs. This one-shot UPDATE re-derives every existing WHOOP row's sport_type from the same table sport-map.ts uses, generated directly from that table so the historical data and the live mapper can't drift apart. Unmatched values default to "other", matching the mapper's fallback. Idempotent: the WHERE clause skips rows already on a canonical value, so a re-run touches zero rows.