@ -140,12 +140,6 @@ export class Batch {
* /
# discard _callbacks = new Set ( ) ;
/ * *
* Callbacks that should run only when a fork is committed .
* @ type { Set < ( batch : Batch ) => void > }
* /
# fork _commit _callbacks = new Set ( ) ;
/ * *
* The number of async effects that are currently in flight
* /
@ -634,7 +628,6 @@ export class Batch {
discard ( ) {
for ( const fn of this . # discard _callbacks ) fn ( this ) ;
this . # discard _callbacks . clear ( ) ;
this . # fork _commit _callbacks . clear ( ) ;
this . # unlink ( ) ;
this . # deferred ? . resolve ( ) ;
@ -840,16 +833,6 @@ export class Batch {
this . # discard _callbacks . add ( fn ) ;
}
/** @param {(batch: Batch) => void} fn */
on _fork _commit ( fn ) {
this . # fork _commit _callbacks . add ( fn ) ;
}
run _fork _commit _callbacks ( ) {
for ( const fn of this . # fork _commit _callbacks ) fn ( this ) ;
this . # fork _commit _callbacks . clear ( ) ;
}
settled ( ) {
return ( this . # deferred ? ? = deferred ( ) ) . promise ;
}
@ -1410,10 +1393,6 @@ export function fork(fn) {
source . wv = increment _write _version ( ) ;
}
batch . activate ( ) ;
batch . run _fork _commit _callbacks ( ) ;
batch . deactivate ( ) ;
// trigger any `$state.eager(...)` expressions with the new state.
// eager effects don't get scheduled like other effects, so we
// can't just encounter them during traversal, we need to