mirror of
https://github.com/oxen-io/session-android.git
synced 2025-05-09 11:57:04 +00:00
Fix for notification preference regression
This commit is contained in:
parent
1aa84b145f
commit
01658cc454
@ -97,10 +97,22 @@ public class MessageNotifier {
|
|||||||
|
|
||||||
|
|
||||||
public static void updateNotification(Context context, MasterSecret masterSecret) {
|
public static void updateNotification(Context context, MasterSecret masterSecret) {
|
||||||
|
if (!PreferenceManager.getDefaultSharedPreferences(context)
|
||||||
|
.getBoolean(ApplicationPreferencesActivity.NOTIFICATION_PREF, true))
|
||||||
|
{
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
updateNotification(context, masterSecret, false);
|
updateNotification(context, masterSecret, false);
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void updateNotification(Context context, MasterSecret masterSecret, long threadId) {
|
public static void updateNotification(Context context, MasterSecret masterSecret, long threadId) {
|
||||||
|
if (!PreferenceManager.getDefaultSharedPreferences(context)
|
||||||
|
.getBoolean(ApplicationPreferencesActivity.NOTIFICATION_PREF, true))
|
||||||
|
{
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
if (visibleThread == threadId) {
|
if (visibleThread == threadId) {
|
||||||
DatabaseFactory.getThreadDatabase(context).setRead(threadId);
|
DatabaseFactory.getThreadDatabase(context).setRead(threadId);
|
||||||
sendInThreadNotification(context);
|
sendInThreadNotification(context);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user