浏览代码

fix(nsis): properly handle Webview2 download return value (#11131)

Orvar Segerström 10 月之前
父节点
当前提交
019f94f128

+ 6 - 0
.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. 
+

+ 1 - 1
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)"