Skip to content

Commit

Permalink
Fixed: The Resume button was functional while downloading ZIM files, …
Browse files Browse the repository at this point in the history
…even when they were paused due to no internet connection. We have added a check before pausing or resuming the download. If there is no internet connection, we now display the same "No Internet connection" snackbar message that is shown when attempting to download a book without an internet connection.
  • Loading branch information
MohitMaliDeveloper authored and MohitMaliFtechiz committed Dec 12, 2024
1 parent 8f35a54 commit d2b6e7f
Showing 1 changed file with 4 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -148,6 +148,10 @@ class OnlineLibraryFragment : BaseFragment(), FragmentActivityExtensions {
},
{
context?.let { context ->
if (isNotConnected) {
noInternetSnackbar()
return@let
}
downloader.pauseResumeDownload(
it.downloadId,
it.downloadState.toReadableState(context).contains(getString(string.paused_state))
Expand Down

0 comments on commit d2b6e7f

Please sign in to comment.