network #28

Merged
AmineB merged 28 commits from davidoskky/ReaderForSelfoss-multiplatform:network into master 2022-08-22 19:01:16 +00:00
3 changed files with 74 additions and 69 deletions
Showing only changes of commit d1481a1db6 - Show all commits
@@ -43,7 +43,7 @@ class LoadingWorker(val context: Context, params: WorkerParameters) : Worker(con
override fun doWork(): Result {
val settings = Settings()
val periodicRefresh = settings.getBoolean("periodic_refresh", false)
if (periodicRefresh) {
if (periodicRefresh && repository.isNetworkAvailable()) {
AmineB marked this conversation as resolved Outdated
Outdated
Review

This should be reverted to the old network status check, because the network availability watcher should be stopped when the app is in the background.

This should be reverted to the old network status check, because the network availability watcher should be stopped when the app is in the background.
CoroutineScope(Dispatchers.IO).launch {
val notificationManager =
AmineB marked this conversation as resolved Outdated
Outdated
Review

I think that this should be the only place where the connectivity check should stay like this.

If there is no network connectivity, you don't do anything in the background.

I think that this should be the only place where the connectivity check should stay like this. If there is no network connectivity, you don't do anything in the background.
Internal Server Error - Amine's git
500 Internal Server Error

Gitea Version: 1.28.0+dev-211-ga30d865b78