Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
emitWithResult(event, timeout, timeoutMessage, ...args) {
const asyncFuncList = this.listeners(event).map(listener => PageManager.makePromise(event, timeout, timeoutMessage, listener, ...args));
return Promise.all(asyncFuncList);
}