1
0
mirror of https://github.com/fuse-friends/fuse-native synced 2024-10-27 18:34:01 +00:00

better default handling in error case

This commit is contained in:
Andrew Osheroff 2019-08-07 12:44:13 +02:00
parent 97f6e37003
commit b48d260d9e

View File

@ -216,8 +216,8 @@ class Fuse extends Nanoresource {
} }
function signal (nativeHandler, err, ...args) { function signal (nativeHandler, err, ...args) {
const arr = [nativeHandler, err, ...args] var arr = [nativeHandler, err, ...args]
if (defaults && (!args || !args.length)) arr.concat(defaults) if (defaults && (!args || !args.length)) arr = arr.concat(defaults)
return process.nextTick(nativeSignal, ...arr) return process.nextTick(nativeSignal, ...arr)
} }
} }