(detail, progressCallback = null)
| 51 | } |
| 52 | |
| 53 | _sendRequest(detail, progressCallback = null) { |
| 54 | if (!this.valid) throw 'No native'; |
| 55 | |
| 56 | const requestId = this.nextRequestId++; |
| 57 | return new Promise((resolve, reject) => { |
| 58 | this.requests.set(requestId, { |
| 59 | resolve, |
| 60 | reject, |
| 61 | progressCallback |
| 62 | }); |
| 63 | |
| 64 | this.nativeUpdater.command(JSON.stringify([ requestId, detail ])); |
| 65 | }); |
| 66 | } |
| 67 | |
| 68 | _sendRequestSync(detail) { |
| 69 | if (!this.valid) throw 'No native'; |
no test coverage detected