Skip to main content

should_fire_fixed_now

Function should_fire_fixed_now 

Source
pub fn should_fire_fixed_now(
    today: &str,
    current_min: u32,
    last_fire: Option<&(String, u32)>,
) -> bool
Expand description

Dedupe gate for fixed-time fires: true unless we already fired this exact (date, minute) slot. Prevents the 1Hz tick from firing the same fixed slot up to 60 times, and (because the key includes the local date) stays correct across DST: 02:00 on a “fall back” day fires once even though the wall clock visits it twice, and 02:30 on a “spring forward” day simply never matches.