[Fix] nvm unload: run nvm deactivate before unsetting everything.

Fixes #1399.
This commit is contained in:
Jordan Harband
2017-02-18 00:50:33 -08:00
parent e7e4a9b3d6
commit b54e147442

1
nvm.sh
View File

@@ -3166,6 +3166,7 @@ nvm() {
nvm_echo '0.33.0' nvm_echo '0.33.0'
;; ;;
"unload" ) "unload" )
nvm deactivate >/dev/null 2>&1
unset -f nvm \ unset -f nvm \
nvm_iojs_prefix nvm_node_prefix \ nvm_iojs_prefix nvm_node_prefix \
nvm_add_iojs_prefix nvm_strip_iojs_prefix \ nvm_add_iojs_prefix nvm_strip_iojs_prefix \