fixed exception when push the button 'on' and no page loaded, now into console sending a message with error