From 7908a14bfe138d5121b046733b90376416fb1f61 Mon Sep 17 00:00:00 2001 From: joragua Date: Wed, 4 Dec 2024 13:15:34 +0100 Subject: [PATCH] fix: set the correct backup account in UI and not the current one --- .../settings/automaticuploads/SettingsPictureUploadsFragment.kt | 2 +- .../settings/automaticuploads/SettingsVideoUploadsFragment.kt | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/owncloudApp/src/main/java/com/owncloud/android/presentation/settings/automaticuploads/SettingsPictureUploadsFragment.kt b/owncloudApp/src/main/java/com/owncloud/android/presentation/settings/automaticuploads/SettingsPictureUploadsFragment.kt index cb7a19de19b..730108e8132 100644 --- a/owncloudApp/src/main/java/com/owncloud/android/presentation/settings/automaticuploads/SettingsPictureUploadsFragment.kt +++ b/owncloudApp/src/main/java/com/owncloud/android/presentation/settings/automaticuploads/SettingsPictureUploadsFragment.kt @@ -149,7 +149,7 @@ class SettingsPictureUploadsFragment : PreferenceFragmentCompat() { picturesViewModel.pictureUploads.collect { pictureUploadsConfiguration -> enablePictureUploads(pictureUploadsConfiguration != null, false) pictureUploadsConfiguration?.let { - prefPictureUploadsAccount?.value = selectedAccount + prefPictureUploadsAccount?.value = it.accountName prefPictureUploadsPath?.summary = picturesViewModel.getUploadPathString() prefPictureUploadsSourcePath?.summary = DisplayUtils.getPathWithoutLastSlash(it.sourcePath.toUri().path) prefPictureUploadsOnWifi?.isChecked = it.wifiOnly diff --git a/owncloudApp/src/main/java/com/owncloud/android/presentation/settings/automaticuploads/SettingsVideoUploadsFragment.kt b/owncloudApp/src/main/java/com/owncloud/android/presentation/settings/automaticuploads/SettingsVideoUploadsFragment.kt index 5adb6ff0dc2..9d1f39b2b45 100644 --- a/owncloudApp/src/main/java/com/owncloud/android/presentation/settings/automaticuploads/SettingsVideoUploadsFragment.kt +++ b/owncloudApp/src/main/java/com/owncloud/android/presentation/settings/automaticuploads/SettingsVideoUploadsFragment.kt @@ -146,7 +146,7 @@ class SettingsVideoUploadsFragment : PreferenceFragmentCompat() { videosViewModel.videoUploads.collect { videoUploadsConfiguration -> enableVideoUploads(videoUploadsConfiguration != null, false) videoUploadsConfiguration?.let { - prefVideoUploadsAccount?.value = selectedAccount + prefVideoUploadsAccount?.value = it.accountName prefVideoUploadsPath?.summary = videosViewModel.getUploadPathString() prefVideoUploadsSourcePath?.summary = DisplayUtils.getPathWithoutLastSlash(it.sourcePath.toUri().path) prefVideoUploadsOnWifi?.isChecked = it.wifiOnly