From 0be2efc2751a609402212a1b8c9a5b41ce1e313e Mon Sep 17 00:00:00 2001 From: Oussama Sethoum <88779394+oSethoum@users.noreply.github.com> Date: Wed, 12 Mar 2025 20:48:05 +0100 Subject: [PATCH] fix: general auto save and general password auto save always enabled --- v3/pkg/application/webview_window_windows.go | 29 ++++++++------------ 1 file changed, 12 insertions(+), 17 deletions(-) diff --git a/v3/pkg/application/webview_window_windows.go b/v3/pkg/application/webview_window_windows.go index 89bea1cbd..ecd20002f 100644 --- a/v3/pkg/application/webview_window_windows.go +++ b/v3/pkg/application/webview_window_windows.go @@ -1665,26 +1665,21 @@ func (w *windowsWebviewWindow) setupChromium() { } - if opts.GeneralAutofillEnabled { - err = chromium.PutIsGeneralAutofillEnabled(true) - if err != nil { - if errors.Is(edge.UnsupportedCapabilityError, err) { - // warning - globalApplication.warning("unsupported capability: GeneralAutofillEnabled") - } else { - globalApplication.handleFatalError(err) - } + err = chromium.PutIsGeneralAutofillEnabled(opts.GeneralAutofillEnabled) + if err != nil { + if errors.Is(err, edge.UnsupportedCapabilityError) { + globalApplication.warning("unsupported capability: GeneralAutofillEnabled") + } else { + globalApplication.handleFatalError(err) } } - if opts.PasswordAutosaveEnabled { - err = chromium.PutIsPasswordAutosaveEnabled(true) - if err != nil { - if errors.Is(edge.UnsupportedCapabilityError, err) { - globalApplication.warning("unsupported capability: PasswordAutosaveEnabled") - } else { - globalApplication.handleFatalError(err) - } + err = chromium.PutIsPasswordAutosaveEnabled(opts.PasswordAutosaveEnabled) + if err != nil { + if errors.Is(err, edge.UnsupportedCapabilityError) { + globalApplication.warning("unsupported capability: PasswordAutosaveEnabled") + } else { + globalApplication.handleFatalError(err) } }