Fix cannot show push notification on android
(cherry picked from commit 07f1b44da20eddb412f36d982f2e08e0ca6d7f71)
This commit is contained in:
+2
-3
@@ -88,6 +88,8 @@ class LocalNotificationManager {
|
||||
final granted = await _isAndroidPermissionGranted();
|
||||
if (!granted) {
|
||||
_notificationsEnabled = await _requestPermissions();
|
||||
} else {
|
||||
_notificationsEnabled = granted;
|
||||
}
|
||||
} else {
|
||||
_notificationsEnabled = await _requestPermissions();
|
||||
@@ -131,9 +133,6 @@ class LocalNotificationManager {
|
||||
EmailAddress? emailAddress,
|
||||
String? payload
|
||||
}) async {
|
||||
if (!_notificationsEnabled) {
|
||||
return;
|
||||
}
|
||||
final inboxStyleInformation = InboxStyleInformation(
|
||||
[message?.addBlockTag('p', attribute: 'style="color:#6D7885;"') ?? ''],
|
||||
htmlFormatLines: true,
|
||||
|
||||
Reference in New Issue
Block a user