declaration of undoHelperCheckMate