Skip to content

Commit

Permalink
$NODE_PATH is special, so this function shouldn't risk clobbering it.
Browse files Browse the repository at this point in the history
  • Loading branch information
ljharb committed Nov 28, 2014
1 parent 7bbcd3a commit 0527438
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions nvm.sh
Original file line number Diff line number Diff line change
Expand Up @@ -253,11 +253,11 @@ nvm_alias() {
}

nvm_ls_current() {
local NODE_PATH
NODE_PATH="$(which node 2> /dev/null)"
local NVM_LS_CURRENT_NODE_PATH
NVM_LS_CURRENT_NODE_PATH="$(which node 2> /dev/null)"
if [ $? -ne 0 ]; then
echo 'none'
elif nvm_tree_contains_path "$NVM_DIR" "$NODE_PATH"; then
elif nvm_tree_contains_path "$NVM_DIR" "$NVM_LS_CURRENT_NODE_PATH"; then
local VERSION
VERSION=`node -v 2>/dev/null`
if [ "$VERSION" = "v0.6.21-pre" ]; then
Expand Down

0 comments on commit 0527438

Please sign in to comment.