Skip to content

Commit cc5a8bd

Browse files
author
Ilya Radchenko
committed
Merge pull request #26 from terasaka2k/master
Fix wildcard of emitter subscription
2 parents 68b77f6 + 02d3a0b commit cc5a8bd

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

lib/index.js

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -141,9 +141,7 @@ Runner.prototype = {
141141
if (!job) return
142142
self.emitter.emit('browser.update', project, this.event, [].slice.call(arguments))
143143
}
144-
this.io.on('job.status.*', proxy)
145-
this.io.on('job.status.*.*', proxy)
146-
this.io.on('job.status.*.*.*', proxy)
144+
this.io.on('job.status.**', proxy)
147145
this.io.on('job.cancelled', function (id) {
148146
// our running job was cancelled, so we need to start the next one
149147
var jobdata = self.jobdata.pop(id)
@@ -170,7 +168,7 @@ Runner.prototype = {
170168
delete self.callbackMap[id]
171169
})
172170
// proxy up plugin events
173-
this.io.on('plugin.*.*', function () {
171+
this.io.on('plugin.**', function () {
174172
self.emitter.emit.apply(self.emitter, [this.event].concat([].slice.call(arguments)))
175173
})
176174
},

0 commit comments

Comments
 (0)