events.js: do not apply event handlers without...

...an Icinga object. Added a log line, eventually we'll catch this one
far day :)
This commit is contained in:
Thomas Gelf 2016-02-29 22:11:30 +01:00
parent 28204762ab
commit b6fd4f5584
1 changed files with 6 additions and 0 deletions

View File

@ -36,6 +36,12 @@
var self = event.data.self;
var icinga = self.icinga;
if (! icinga) {
// Attempt to catch a rare error, race condition, whatever
console.log('Got no icinga in applyHandlers');
return;
}
if (self.initializeModules) {
var loaded = false;
var moduleName = $target.data('icingaModule');