ensure Metamaps[prop] is an object
This commit is contained in:
parent
6cd988fb31
commit
b64558f860
1 changed files with 2 additions and 1 deletions
|
@ -49,7 +49,8 @@ $(document).ready(function () {
|
|||
// this runs the init function within each sub-object on the Metamaps one
|
||||
if (Metamaps.hasOwnProperty(prop) &&
|
||||
Metamaps[prop].hasOwnProperty('init') &&
|
||||
typeof (Metamaps[prop].init) == 'function'
|
||||
typeof Metamaps[prop] === 'object' &&
|
||||
typeof (Metamaps[prop].init) === 'function'
|
||||
) {
|
||||
Metamaps[prop].init();
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue