@wdio/sync
Advanced tools
Comparing version 5.7.8 to 5.7.9
@@ -19,7 +19,11 @@ "use strict"; | ||
return function (...args) { | ||
return new Promise(resolve => (0, _fibers.default)(() => { | ||
const result = fn.apply(this, args); | ||
resolve(result); | ||
return new Promise((resolve, reject) => (0, _fibers.default)(() => { | ||
try { | ||
const result = fn.apply(this, args); | ||
return resolve(result); | ||
} catch (err) { | ||
return reject(err); | ||
} | ||
}).run()); | ||
}; | ||
} |
{ | ||
"name": "@wdio/sync", | ||
"version": "5.7.8", | ||
"version": "5.7.9", | ||
"description": "A WebdriverIO plugin. Helper module to run WebdriverIO commands synchronously", | ||
@@ -44,3 +44,3 @@ "author": "Christian Bromann <christian@saucelabs.com>", | ||
}, | ||
"gitHead": "d96a4a8a313b7fd855f102af6198c60cf8475b8e" | ||
"gitHead": "392503e9599dbdbe69ad5232dd601c064b76f6e3" | ||
} |
26506
745