Skip to content

armgit / ente

Public Imported from GitHub
0

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

Simplify notification ID

laurenspriema1ef8d33d32b
diff --git a/mobile/lib/services/memories_cache_service.dart b/mobile/lib/services/memories_cache_service.dart
index e3bcc5c32c..21b9ab6f79 100644
--- a/mobile/lib/services/memories_cache_service.dart
+++ b/mobile/lib/services/memories_cache_service.dart
@@ -275,7 +275,7 @@ class MemoriesCacheService {
id: memory.id.hashCode,
channelID: "onThisDay",
channelName: "On this day",
- payload: "onThisDay_${memory.id}",
+ payload: memory.id,
dateTime: scheduleTime,
);
scheduledDates.add(scheduleTime);
diff --git a/mobile/lib/ui/tabs/home_widget.dart b/mobile/lib/ui/tabs/home_widget.dart
index 2e8f510480..55364a9656 100644
--- a/mobile/lib/ui/tabs/home_widget.dart
+++ b/mobile/lib/ui/tabs/home_widget.dart
@@ -854,11 +854,9 @@ class _HomeWidgetState extends State<HomeWidget> {
if (payload != null) {
debugPrint('notification payload: $payload');
if (payload.toLowerCase().contains("onthisday")) {
- final String memoryID = payload.substring(payload.indexOf("_") + 1);
- // ignore: unawaited_futures
await memoriesCacheService.goToMemoryFromMemoryID(
context,
- memoryID,
+ payload,
);
} else {
final collectionID = Uri.parse(payload).queryParameters["collectionID"];