Skip to content

Commit

Permalink
Assert that _maybeCreateRouterFor runs in the computed zone
Browse files Browse the repository at this point in the history
  • Loading branch information
mstniy committed Dec 17, 2023
1 parent ebc59c1 commit 19f011a
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions lib/src/computed.dart
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,7 @@ class GlobalCtx {
? _ValueOrException.value(currentValue())
: null);
GlobalCtx._routerExpando[dataSource] = rvoe;
assert(Zone.current[_isComputedZone] == true, "Corrupt internal state");
final sub = Zone.current.parent!.run(() => dss(rvoe!._router));

rvoe._router._dss ??= _DataSourceAndSubscription<T>(dataSource,
Expand Down

0 comments on commit 19f011a

Please sign in to comment.