Skip to main content

next_state

Function next_state 

Source
pub fn next_state(stats: &SkillStats, now: DateTime<Utc>) -> LifecycleState
Expand description

Compute what state the skill should be in given its current stats and the current time. PURE — does not mutate. Idempotent: calling this twice with the same inputs returns the same output.

Caller (M5b sweep, or M5a doctor preview) decides whether to persist or merely display the result.