diff --git a/src/state/transition/mod.rs b/src/state/transition/mod.rs index 51fce8fae..4564453fa 100644 --- a/src/state/transition/mod.rs +++ b/src/state/transition/mod.rs @@ -43,7 +43,13 @@ pub fn compute_state_transition ( { let is_new_epoch = parent_act_state.height % config.epoch_length == 0; - + + /* + * If this transition will push the chain into a new epoch, + * calculate a new crystallized state and "reset" the + * current active state. Otherwise, continue with the existing + * state pair. + */ let (cry_state, mut act_state) = match is_new_epoch { false => (parent_cry_state.clone(), parent_act_state.clone()), true => initialize_new_epoch( @@ -58,7 +64,6 @@ pub fn compute_state_transition ( "epoch" => cry_state.current_epoch); } - act_state = compute_new_active_state( &cry_state, &act_state,