Tweak the logic for successful WASM install #1903
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Fixes #1902
The core problem is the test for a successful install was this:
However,
HandleWasmInstall()
returns false if there was nothing to do (because the correct version is already installed). So users with an up-to-date 2020 install, and no 2024 install, would wind up withfalse
as the return from each of theHandleWasmInstall()
calls. That skips the success message and falls through to an error.The fix is to:
Update2020Successful
andUpdate2024Successful
totrue
HandleWasmInstall()
if the modules are "different" (which also includes non-existent)At least I think this fixes it. I tested by hand-hacking the path to the MSFS2024 community folder to be non-existent (to simulate 2024 not being installed) and it works.