Skip to content
Myr

Oops, still had some proto code in there

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by ciaranj · committed by ciaranj · parent 4063d2e · Browse files · 1 file+12 added−19 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+12 added−19 removed

  • other:+12 added−19 removed

1 file+12 added−19 removed

modified:lib/express/request.js+12 added-19 removed
230 unmodified lines
231 var pluginsExecuted= 0,232 plugin= undefined,233 totalPlugins= this.plugins.length(),234 self= this;235 if( callback ) { 236 var callNextPlugin= function(error) {237 if( error || pluginsExecuted >= totalPlugins ) callback(error); // All the plugins have called back or there was an error ..238 else {239 try{240 plugin= self.plugins.at(pluginsExecuted++);241 if( plugin && plugin.trigger ) plugin.trigger(new Event(name, data), callNextPlugin)242 else callNextPlugin();243 } catch(e) {244 callNextPlugin(e);235 var callNextPlugin= function(error) {236 if( error || pluginsExecuted >= totalPlugins ) callback(error); // All the plugins have called back or there was an error ..237 else {238 try{239 plugin= self.plugins.at(pluginsExecuted++);240 if( plugin && plugin.trigger ) plugin.trigger(new Event(name, data), callNextPlugin)241 else callNextPlugin();242 } catch(e) {243 callNextPlugin(e);245 }244 }247 }; 248 callNextPlugin();249 }250 else {251 this.plugins.each(function(plugin){252 plugin.trigger(new Event(name, data)) 253 }) 254 }245 }246 }; 247 callNextPlugin();248 return this249 },250 251 /**
41 unmodified lines