Fix infinite loop of error messages when an invalid command is displayed in the hotkey editor