Sometimes deploy script fails to detect the global cli version. it happens if user has installed Node via [Volta] (https://volta.sh/) or something similar. In that case npm list -g --depth 0 --json --silent doesn't include zkapp-cli.
If that happens, getInstalledCliVersion method returns undefined and code breaks.
Changes summary
To fix this, check the return value of getInstalledCliVersion and if is undefined, show a relevant message to user.
550
Issue Description
Sometimes deploy script fails to detect the global cli version. it happens if user has installed Node via [Volta] (https://volta.sh/) or something similar. In that case
npm list -g --depth 0 --json --silent
doesn't includezkapp-cli
.If that happens,
getInstalledCliVersion
method returnsundefined
and code breaks.Changes summary
To fix this, check the return value of
getInstalledCliVersion
and if is undefined, show a relevant message to user.