Use unique request code to make sure that a new PendingIntent gets created for each notification

Signed-off-by: Dariusz Olszewski <starypatyk@users.noreply.github.com>
This commit is contained in:
Dariusz Olszewski 2022-06-06 00:10:51 +02:00 committed by Marcel Hibbe (Rebase PR Action)
parent 7a972a99da
commit f1dfb00ae0

View File

@ -292,7 +292,10 @@ public class NotificationWorker extends Worker {
}
}
PendingIntent pendingIntent = PendingIntent.getActivity(context, 0, intent, 0);
// Use unique request code to make sure that a new PendingIntent gets created for each notification
// See https://github.com/nextcloud/talk-android/issues/2111
int requestCode = (int) System.currentTimeMillis();
PendingIntent pendingIntent = PendingIntent.getActivity(context, requestCode, intent, 0);
Uri uri = Uri.parse(signatureVerification.getUserEntity().getBaseUrl());
String baseUrl = uri.getHost();