[Fix] `set -u`: `nvm use`: ensure these two vars don’t error out.
Fixes #1587.
parent
248706d5f8
commit
389a53cca9
4
nvm.sh
4
nvm.sh
|
@ -2807,9 +2807,9 @@ nvm() {
|
|||
|
||||
if [ -n "${NVM_LTS-}" ]; then
|
||||
VERSION="$(nvm_match_version "lts/${NVM_LTS:-*}")"
|
||||
elif [ -z "$PROVIDED_VERSION" ]; then
|
||||
elif [ -z "${PROVIDED_VERSION-}" ]; then
|
||||
nvm_rc_version
|
||||
if [ -n "$NVM_RC_VERSION" ]; then
|
||||
if [ -n "${NVM_RC_VERSION-}" ]; then
|
||||
PROVIDED_VERSION="$NVM_RC_VERSION"
|
||||
VERSION="$(nvm_version "$PROVIDED_VERSION")"
|
||||
fi
|
||||
|
|
Loading…
Reference in New Issue