events.js: reduce logging noise

Form submission by pressing return is not an error, and debug level
should suffice for the other button-related notices too.
This commit is contained in:
Thomas Gelf 2015-02-02 21:56:14 +01:00
parent a705e03aff
commit f6fc592b91
1 changed files with 3 additions and 3 deletions

View File

@ -204,16 +204,16 @@
if (typeof event.originalEvent !== 'undefined' if (typeof event.originalEvent !== 'undefined'
&& typeof event.originalEvent.explicitOriginalTarget === 'object') { // Firefox && typeof event.originalEvent.explicitOriginalTarget === 'object') { // Firefox
$el = $(event.originalEvent.explicitOriginalTarget); $el = $(event.originalEvent.explicitOriginalTarget);
icinga.logger.info('events/submitForm: Button is event.originalEvent.explicitOriginalTarget'); icinga.logger.debug('events/submitForm: Button is event.originalEvent.explicitOriginalTarget');
} else { } else {
$el = $(event.currentTarget); $el = $(event.currentTarget);
icinga.logger.info('events/submitForm: Button is event.currentTarget'); icinga.logger.debug('events/submitForm: Button is event.currentTarget');
} }
if ($el && ($el.is('input[type=submit]') || $el.is('button[type=submit]'))) { if ($el && ($el.is('input[type=submit]') || $el.is('button[type=submit]'))) {
$button = $el; $button = $el;
} else { } else {
icinga.logger.error( icinga.logger.debug(
'events/submitForm: Can not determine submit button, using the first one in form' 'events/submitForm: Can not determine submit button, using the first one in form'
); );
} }