Fix revert code so that it executes