This can help:
$ sudo npm install -g n $ sudo npm cache clean -f $ sudo n stable
also you can replase stable with latest.
NOTE: if $ node -v shows the old version, open a new shell.
$ node -v