async-another-try
Simon Holthausen 4 days ago
parent 54d8c3d843
commit 48100417b5
No known key found for this signature in database

@ -1554,21 +1554,19 @@ export function fork(fn) {
e.fork_timing(); e.fork_timing();
} }
var committed = false; flushSync();
/** @type {Promise<void>} */
var settled;
/** @type {Batch} */
var batch;
flushSync(() => { var committed = false;
batch = Batch.ensure(); var batch = Batch.ensure();
batch.is_fork = true; batch.is_fork = true;
batch_values = new Map(); batch_values = new Map();
wv_values = new Map(); wv_values = new Map();
settled = batch.settled();
var settled = batch.settled();
fn(); fn();
}); flushSync();
return { return {
commit: async () => { commit: async () => {

Loading…
Cancel
Save