1
0
mirror of https://github.com/node-red/node-red.git synced 2023-10-10 13:36:53 +02:00

make close handler argument only one

This commit is contained in:
Hiroyasu Nishiyama 2018-10-02 20:37:30 +09:00
parent 7cec7ae608
commit 58c8311d56

View File

@ -189,8 +189,7 @@ module.exports = function(RED) {
}
}
this.on('close', function(arg1, arg2) {
var cb = arg2 ? arg2 : arg1;
this.on('close', function(cb) {
if (cb) {
node.closeCallbacks.push(done);
}