From 13a495d18917f9b8952088b4a3e960239c5a168c Mon Sep 17 00:00:00 2001 From: cyBerta Date: Mon, 28 Dec 2020 18:44:00 +0100 Subject: cancel ongoing download notification if download failed --- .../java/se.leap.bitmaskclient/appUpdate/DownloadBroadcastReceiver.java | 1 + 1 file changed, 1 insertion(+) diff --git a/app/src/fatweb/java/se.leap.bitmaskclient/appUpdate/DownloadBroadcastReceiver.java b/app/src/fatweb/java/se.leap.bitmaskclient/appUpdate/DownloadBroadcastReceiver.java index 525c3c9b..a4acc2aa 100644 --- a/app/src/fatweb/java/se.leap.bitmaskclient/appUpdate/DownloadBroadcastReceiver.java +++ b/app/src/fatweb/java/se.leap.bitmaskclient/appUpdate/DownloadBroadcastReceiver.java @@ -81,6 +81,7 @@ public class DownloadBroadcastReceiver extends BroadcastReceiver { } else { Toast.makeText(context.getApplicationContext(), context.getString(R.string.version_update_error), Toast.LENGTH_LONG).show(); } + notificationManager.cancelNotifications(); break; case DOWNLOAD_PROGRESS: int progress = resultData.getInt(PROGRESS_VALUE, 0); -- cgit v1.2.3