This commit is contained in:
David Luhmer 2018-12-27 13:23:17 +01:00
parent 5e11303e87
commit 60fe4a568b

View file

@ -237,9 +237,9 @@ public class OwnCloudSyncAdapter extends AbstractThreadedSyncAdapter {
if(newItemsCount > 0) {
String fgActivityPackageName = getForegroundActivityPackageName();
boolean showNotifcationOnNewArticles = mPrefs.getBoolean(SettingsActivity.CB_SHOW_NOTIFICATION_NEW_ARTICLES_STRING, true);
boolean showNotificationOnNewArticles = mPrefs.getBoolean(SettingsActivity.CB_SHOW_NOTIFICATION_NEW_ARTICLES_STRING, true);
// If another app is opened show a notification
if (!fgActivityPackageName.equals(getContext().getPackageName()) && showNotifcationOnNewArticles) {
if (!fgActivityPackageName.equals(getContext().getPackageName()) && showNotificationOnNewArticles) {
NextcloudNotificationManager.showUnreadRssItemsNotification(getContext(), newItemsCount);
}
}