mirror of
https://github.com/nvm-sh/nvm.git
synced 2026-04-05 20:44:51 +08:00
[Fix] nvm_iojs_version_has_solaris_binary: fix comparison to detect non-iojs versions
Missing `_` prefix on the right side of the comparison meant the guard clause that rejects non-iojs versions almost never matched, allowing non-iojs versions to fall through.
Bug introduced in 2d692d9d78 / #854.
This commit is contained in:
2
nvm.sh
2
nvm.sh
@@ -2967,7 +2967,7 @@ nvm_iojs_version_has_solaris_binary() {
|
||||
IOJS_VERSION="$1"
|
||||
local STRIPPED_IOJS_VERSION
|
||||
STRIPPED_IOJS_VERSION="$(nvm_strip_iojs_prefix "${IOJS_VERSION}")"
|
||||
if [ "_${STRIPPED_IOJS_VERSION}" = "${IOJS_VERSION}" ]; then
|
||||
if [ "_${STRIPPED_IOJS_VERSION}" = "_${IOJS_VERSION}" ]; then
|
||||
return 1
|
||||
fi
|
||||
|
||||
|
||||
Reference in New Issue
Block a user