Update: Enforce notification on manual sync

This commit is contained in:
machiav3lli 2022-07-09 01:31:26 +02:00
parent 717d653644
commit 569d6aaac4

View File

@ -391,7 +391,6 @@ class SyncService : ConnectionService<SyncService.Binder>() {
.observeOn(AndroidSchedulers.mainThread()) .observeOn(AndroidSchedulers.mainThread())
.subscribe { result, throwable -> .subscribe { result, throwable ->
throwable?.printStackTrace() throwable?.printStackTrace()
currentTask = null
if (result.isNotEmpty()) { if (result.isNotEmpty()) {
if (Preferences[Preferences.Key.InstallAfterSync]) if (Preferences[Preferences.Key.InstallAfterSync])
batchUpdate(result) batchUpdate(result)
@ -399,8 +398,12 @@ class SyncService : ConnectionService<SyncService.Binder>() {
updateNotificationBlockerFragment?.get()?.isAdded != true && updateNotificationBlockerFragment?.get()?.isAdded != true &&
result.isNotEmpty() result.isNotEmpty()
) )
displayUpdatesNotification(result) displayUpdatesNotification(
result,
currentTask?.task?.manual == true
)
} }
currentTask = null
handleNextTask(false) handleNextTask(false)
} }
if (hasUpdates) { if (hasUpdates) {