@leofcoin/workers 1.4.17 → 1.4.18
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +6 -0
- package/package.json +1 -1
- package/src/machine-worker.js +1 -2
package/CHANGELOG.md
CHANGED
package/package.json
CHANGED
package/src/machine-worker.js
CHANGED
|
@@ -4,7 +4,6 @@ import addresses from '@leofcoin/addresses'
|
|
|
4
4
|
import bytecodes from '@leofcoin/lib/bytecodes' assert { type: 'json' }
|
|
5
5
|
import EasyWorker from '@vandeurenglenn/easy-worker'
|
|
6
6
|
import { nativeToken } from '@leofcoin/addresses'
|
|
7
|
-
import { randomUUID } from 'crypto'
|
|
8
7
|
import LittlePubSub from '@vandeurenglenn/little-pubsub'
|
|
9
8
|
const pubsub = new LittlePubSub()
|
|
10
9
|
const worker = new EasyWorker()
|
|
@@ -275,7 +274,7 @@ _.loadBlock = (block) => {
|
|
|
275
274
|
|
|
276
275
|
const askFor = (question, input) =>
|
|
277
276
|
new Promise((resolve) => {
|
|
278
|
-
const id = randomUUID()
|
|
277
|
+
const id = globalThis.crypto.randomUUID()
|
|
279
278
|
pubsub.subscribe(id, resolve)
|
|
280
279
|
worker.postMessage({
|
|
281
280
|
type: 'ask',
|