winston.warn('[plugins/'+hookObj.id+'] "callbacked" deprecated as of 0.4x. Use asynchronous method instead for hook: '+hook);
next(null,[value]);
}
}else{
winston.warn('[plugins/'+hookObj.id+'] "callbacked" deprecated as of 0.4x. Use asynchronous method instead for hook: '+hook);
value=hookObj.method.apply(Plugins,value);
next(null,[value]);
}
/* End backwards compatibility block */
}else{
if(global.env==='development'){
winston.info('[plugins] Expected method for hook \''+hook+'\' in plugin \''+hookObj.id+'\' not found, skipping.');
}
next(null,[value]);
}
},function(err,values){
if(err){
if(global.env==='development'){
winston.info('[plugins] Problem executing hook: '+hook+' err: '+JSON.stringify(err));
}
}
if(callback){
callback.apply(Plugins,[err].concat(values));
}
});
break;
case'action':
vardeprecationWarn=[];
async.each(hookList,function(hookObj,next){
/*
Backwardscompatibilityblockforv0.5.0
RemovethisonceNodeBBentersv0.6.0-1
*/
if(hook==='action:app.load'){
deprecationWarn.push(hookObj.id);
}
/* End backwards compatibility block */
if(hookObj.method){
hookObj.method.apply(Plugins,args);
}else{
if(global.env==='development'){
winston.info('[plugins] Expected method \''+hookObj.method+'\' in plugin \''+hookObj.id+'\' not found, skipping.');
}
}
next();
},function(){
/*
Backwardscompatibilityblockforv0.5.0
RemovethisonceNodeBBentersv0.6.0-1
*/
if(deprecationWarn.length){
winston.warn('[plugins] The `action:app.load` hook is deprecated in favour of `static:app.load`, please notify the developers of the following plugins:');