From: Claudio Cambra Date: Wed, 6 Mar 2024 17:12:19 +0000 (+0800) Subject: Properly handle failure state when creating new share in share options view X-Git-Tag: archive/raspbian/3.16.7-1_deb13u1+rpi1~1^2~79^2^2~46^2~49 X-Git-Url: https://dgit.raspbian.org/?a=commitdiff_plain;h=8a9dee72a18fda41688e422f5ecc3b7c22df7114;p=nextcloud-desktop.git Properly handle failure state when creating new share in share options view Signed-off-by: Claudio Cambra --- diff --git a/shell_integration/MacOSX/NextcloudIntegration/FileProviderUIExt/ShareOptionsView.swift b/shell_integration/MacOSX/NextcloudIntegration/FileProviderUIExt/ShareOptionsView.swift index ef4274261..b8ecf3eae 100644 --- a/shell_integration/MacOSX/NextcloudIntegration/FileProviderUIExt/ShareOptionsView.swift +++ b/shell_integration/MacOSX/NextcloudIntegration/FileProviderUIExt/ShareOptionsView.swift @@ -200,8 +200,11 @@ class ShareOptionsView: NSView { ) if let error = error, error != .success { dataSource.uiDelegate?.showError("Error creating: \(error.errorDescription)") + setAllFields(enabled: true) + } else { + dataSource.uiDelegate?.hideOptions() + await dataSource.reload() } - await dataSource.reload() return }