Skip to content

armgit / ente

Public Imported from GitHub
0

πŸ’š End-to-end encrypted cloud for everything.

fix: notification permission error

Prateek Sunal3f99bb55116a
diff --git a/mobile/lib/services/notification_service.dart b/mobile/lib/services/notification_service.dart
index ca9be19b54..c860f427f8 100644
--- a/mobile/lib/services/notification_service.dart
+++ b/mobile/lib/services/notification_service.dart
@@ -23,9 +23,8 @@ class NotificationService {
Future<void> init(
void Function(
NotificationResponse notificationResponse,
- )
- onNotificationTapped,
- SharedPreferences preferences,
+ ) onNotificationTapped,
+ SharedPreferences preferences,
) async {
_preferences = preferences;
const androidSettings = AndroidInitializationSettings('notification_icon');
@@ -72,7 +71,7 @@ class NotificationService {
result = await _notificationsPlugin
.resolvePlatformSpecificImplementation<
AndroidFlutterLocalNotificationsPlugin>()
- ?.requestPermission();
+ ?.requestNotificationsPermission();
}
if (result != null) {
await _preferences.setBool(keyGrantedNotificationPermission, result);