mirror of
https://github.com/status-im/react-native.git
synced 2025-02-03 21:24:31 +00:00
Fix Promise resolve callback error
Reviewed By: theoy Differential Revision: D5032525 fbshipit-source-id: 19680cef70f11cccf2abf03d1c1b7e72ac32e43e
This commit is contained in:
parent
de4d35536d
commit
7dd2cd30af
@ -162,9 +162,9 @@ class Device {
|
||||
this._handlers.delete(name);
|
||||
reject(new Error('Timeout waiting for device'));
|
||||
}, DEVICE_TIMEOUT);
|
||||
this._handlers.set(name, (...args) => {
|
||||
this._handlers.set(name, arg => {
|
||||
clearTimeout(timerId);
|
||||
fulfill(...args);
|
||||
fulfill(arg);
|
||||
});
|
||||
});
|
||||
this._send({event: name});
|
||||
|
Loading…
x
Reference in New Issue
Block a user