Default plugin should not fail if clientVars is not defined.
In the case that it is not defined, the configuration is `undefined`.pull/344/head
parent
0f7e6feda1
commit
6bbc32a19f
|
@ -7,7 +7,8 @@
|
|||
plugins = {
|
||||
callHook: function(hookName, args)
|
||||
{
|
||||
var hook = clientVars.hooks[hookName];
|
||||
var global = (function () {return this}());
|
||||
var hook = ((global.clientVars || {}).hooks || {})[hookName];
|
||||
if (hook === undefined) return [];
|
||||
var res = [];
|
||||
for (var i = 0, N = hook.length; i < N; i++)
|
||||
|
|
Loading…
Reference in New Issue