diff --git a/app/src/main/java/com/nextcloud/talk/receivers/PackageReplacedReceiver.kt b/app/src/main/java/com/nextcloud/talk/receivers/PackageReplacedReceiver.kt
index 604ce0abf..94f47cd10 100644
--- a/app/src/main/java/com/nextcloud/talk/receivers/PackageReplacedReceiver.kt
+++ b/app/src/main/java/com/nextcloud/talk/receivers/PackageReplacedReceiver.kt
@@ -70,7 +70,7 @@ class PackageReplacedReceiver : BroadcastReceiver(), KoinComponent {
appPreferences.setNotificationChannelIsUpgradedToV2(true)
}
- if (!appPreferences.isNotificationChannelUpgradedToV3 && packageInfo.versionCode > 51) {
+ if (!appPreferences.isNotificationChannelUpgradedToV3) {
notificationManager.deleteNotificationChannel(
NotificationUtils.NOTIFICATION_CHANNEL_MESSAGES_V2
)
@@ -80,6 +80,16 @@ class PackageReplacedReceiver : BroadcastReceiver(), KoinComponent {
appPreferences.setNotificationChannelIsUpgradedToV3(true)
}
+ if (!appPreferences.isNotificationChannelUpgradedToV4) {
+ notificationManager.deleteNotificationChannel(
+ NotificationUtils.NOTIFICATION_CHANNEL_MESSAGES_V3
+ )
+ notificationManager.deleteNotificationChannel(
+ NotificationUtils.NOTIFICATION_CHANNEL_CALLS_V3
+ )
+ appPreferences.setNotificationChannelIsUpgradedToV4(true)
+ }
+
}
} catch (e: PackageManager.NameNotFoundException) {
Log.e(TAG, "Failed to fetch package info")
diff --git a/app/src/main/java/com/nextcloud/talk/utils/preferences/AppPreferences.java b/app/src/main/java/com/nextcloud/talk/utils/preferences/AppPreferences.java
index 55db4b761..916212a9e 100644
--- a/app/src/main/java/com/nextcloud/talk/utils/preferences/AppPreferences.java
+++ b/app/src/main/java/com/nextcloud/talk/utils/preferences/AppPreferences.java
@@ -182,6 +182,17 @@ public interface AppPreferences {
@RemoveMethod
void removeNotificationChannelUpgradeToV3();
+ @KeyByString("notification_channels_upgrade_to_v4")
+ boolean getIsNotificationChannelUpgradedToV4();
+
+ @KeyByString("notification_channels_upgrade_to_v4")
+ void setNotificationChannelIsUpgradedToV4(boolean value);
+
+ @KeyByString("notification_channels_upgrade_to_v4")
+ @RemoveMethod
+ void removeNotificationChannelUpgradeToV4();
+
+
@KeyByString("notifications_vibrate")
@DefaultValue(R.bool.value_true)
boolean getShouldVibrateSetting();
diff --git a/app/src/main/res/values/colors.xml b/app/src/main/res/values/colors.xml
index f9526ac4f..8b5578780 100644
--- a/app/src/main/res/values/colors.xml
+++ b/app/src/main/res/values/colors.xml
@@ -41,6 +41,7 @@
#D32F2F
#006400
+ #46FFFFFF
@color/per70white
#7FC0E3
#E8E8E8
@@ -63,7 +64,6 @@
@color/white
#333333
-
#484848
#EFEFEF
@color/colorPrimary