My default editor is pico at my server. I use Bash and Linux.
I tried to change Vim to be my default editor unsuccessfully by
echo vim > $EDITOR
Check this command:
sudo update-alternatives --config editor