android compat for UP
Not fully working yet
This commit is contained in:
parent
6e47594a91
commit
2c3b0e0ab9
1 changed files with 2 additions and 2 deletions
|
|
@ -147,7 +147,7 @@ class UnifiedPushController extends AsyncNotifier<bool> {
|
||||||
vapid: capabilities.webpush?.vapid,
|
vapid: capabilities.webpush?.vapid,
|
||||||
);
|
);
|
||||||
|
|
||||||
if (!alreadyRegistered) ref.invalidateSelf();
|
state = .data(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
Future<void> deregister() async {
|
Future<void> deregister() async {
|
||||||
|
|
@ -167,7 +167,7 @@ class UnifiedPushController extends AsyncNotifier<bool> {
|
||||||
}
|
}
|
||||||
|
|
||||||
await UnifiedPush.unregister(clientState.deviceId!);
|
await UnifiedPush.unregister(clientState.deviceId!);
|
||||||
ref.invalidateSelf();
|
state = .data(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
static final provider = AsyncNotifierProvider<UnifiedPushController, bool>(
|
static final provider = AsyncNotifierProvider<UnifiedPushController, bool>(
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue