Proof using.
unfold handleAppendEntriesReply.
intros.
repeat break_match; repeat find_inversion; simpl in *; auto.
- do_bool. intuition.
- unfold advanceCurrentTerm. break_match; auto.
Qed.

Lemma update_nop_fst :
forall A B f x (v2 : B) y,
fst (update name_eq_dec f x (fst (f x), v2) y) = fst (A := A) (f y).