rollback and branch hooks