state_notifier
state_notifier copied to clipboard
StateNotifierProvider.value doesn't handle LocatorMixin
Describe the bug By using this:
StateNotifierProvider<BalanceStore, BalanceState>(create: (_) => BalanceStore()),
I can use read methods of locatorMixin.
But using:
StateNotifierProvider<BalanceStore, BalanceState>.value(balanceStore),
Then read crash with not found dependency.
By reading the source look like one is setting (value as LocatorMixin)..read = _contextToLocator(context)
but it is not done on the other case.