Fixed issue in Firefox where button presses resulted in errors