(data, rv)
| 160 | }) |
| 161 | } |
| 162 | toData(data, rv) { |
| 163 | if (!(data instanceof ArrayBuffer) && !(data instanceof Uint8Array) && !(data instanceof Blob)) return null; |
| 164 | if (rv) return true; |
| 165 | return new Promise(async (resolve) => { |
| 166 | if (data instanceof ArrayBuffer) { |
| 167 | resolve(new Uint8Array(data)); |
| 168 | } else if (data instanceof Uint8Array) { |
| 169 | resolve(data); |
| 170 | } else if (data instanceof Blob) { |
| 171 | resolve(new Uint8Array(await data.arrayBuffer())); |
| 172 | } |
| 173 | resolve(); |
| 174 | }) |
| 175 | } |
| 176 | checkForUpdates() { |
| 177 | if (this.ejs_version.endsWith("-beta")) { |
| 178 | console.warn("Using EmulatorJS beta. Not checking for updates. This instance may be out of date. Using stable is highly recommended unless you build and ship your own cores."); |
no outgoing calls
no test coverage detected