From 019f94f1284eebdf4fd72c4d1ca6ae096f09449d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Orvar=20Segerstr=C3=B6m?= Date: Thu, 26 Sep 2024 01:38:57 +0200 Subject: [PATCH] fix(nsis): properly handle Webview2 download return value (#11131) --- .changes/bundler-nsis-webview2-success.md | 6 ++++++ tooling/bundler/src/bundle/windows/templates/installer.nsi | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) create mode 100644 .changes/bundler-nsis-webview2-success.md diff --git a/.changes/bundler-nsis-webview2-success.md b/.changes/bundler-nsis-webview2-success.md new file mode 100644 index 000000000000..c2699e904363 --- /dev/null +++ b/.changes/bundler-nsis-webview2-success.md @@ -0,0 +1,6 @@ +--- +"tauri-bundler": "patch:bug" +--- + +Fix NSIS installer failing to determine whether webview installer downloaded correctly or not. + diff --git a/tooling/bundler/src/bundle/windows/templates/installer.nsi b/tooling/bundler/src/bundle/windows/templates/installer.nsi index 7e5832b69941..d2584c7ac1b9 100644 --- a/tooling/bundler/src/bundle/windows/templates/installer.nsi +++ b/tooling/bundler/src/bundle/windows/templates/installer.nsi @@ -457,7 +457,7 @@ Section WebView2 DetailPrint "$(webview2Downloading)" NSISdl::download "https://go.microsoft.com/fwlink/p/?LinkId=2124703" "$TEMP\MicrosoftEdgeWebview2Setup.exe" Pop $0 - ${If} $0 == 0 + ${If} $0 == "success" DetailPrint "$(webview2DownloadSuccess)" ${Else} DetailPrint "$(webview2DownloadError)"