Fixed DownloadLocationDialogFragment keep showing up when any button is clicked
This commit is contained in:
@@ -122,6 +122,9 @@ class DownloadLocationDialogFragment : DialogFragment() {
|
||||
.setTitle(R.string.settings_download_folder)
|
||||
.setView(build())
|
||||
.setPositiveButton(requireContext().getText(android.R.string.ok)) { _, _ ->
|
||||
if (Preferences["download_folder", ""].isEmpty())
|
||||
Preferences["download_folder"] = context?.getExternalFilesDir(null)?.canonicalPath ?: ""
|
||||
|
||||
DownloadManager.getInstance(requireContext()).migrate()
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user