diff --git a/app/src/main/java/com/nextcloud/utils/extensions/BundleExtensions.kt b/app/src/main/java/com/nextcloud/utils/extensions/BundleExtensions.kt index 4d8149597adc..e0d4bd608190 100644 --- a/app/src/main/java/com/nextcloud/utils/extensions/BundleExtensions.kt +++ b/app/src/main/java/com/nextcloud/utils/extensions/BundleExtensions.kt @@ -27,16 +27,18 @@ import android.os.Parcelable import java.io.Serializable fun Bundle.getSerializableArgument(key: String, type: Class): T? { - return if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.TIRAMISU) + return if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.TIRAMISU) { this.getSerializable(key, type) - else + } else { @Suppress("UNCHECKED_CAST") this.getSerializable(key) as T + } } fun Bundle.getParcelableArgument(key: String, type: Class): T? { - return if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.TIRAMISU) + return if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.TIRAMISU) { this.getParcelable(key, type) - else + } else { this.getParcelable(key) -} \ No newline at end of file + } +} diff --git a/app/src/main/java/com/owncloud/android/ui/fragment/FileDetailsSharingProcessFragment.kt b/app/src/main/java/com/owncloud/android/ui/fragment/FileDetailsSharingProcessFragment.kt index d5f3b2fa1bf5..43036e056011 100644 --- a/app/src/main/java/com/owncloud/android/ui/fragment/FileDetailsSharingProcessFragment.kt +++ b/app/src/main/java/com/owncloud/android/ui/fragment/FileDetailsSharingProcessFragment.kt @@ -246,8 +246,11 @@ class FileDetailsSharingProcessFragment : val resources = requireContext().resources binding.shareProcessBtnNext.text = resources.getString( - if (shareType == ShareType.PUBLIC_LINK) R.string.share_copy_link - else R.string.common_confirm + if (shareType == ShareType.PUBLIC_LINK) { + R.string.share_copy_link + } else { + R.string.common_confirm + } ) updateViewForShareType()