Sudo does not change the PATH environment variable.
By default, /usr/bin comes before /usr/local/bin, so the version of nano included will still be run.
The most likely explanation is that in your
.bash_profile or .bashrc (or similar file if you use another shell) you have created an alias - something like
alias nano=/usr/local/bin/nano
One way to get around this is to make /usr/local/bin come *before* /usr/bin in the path.
I have done this so that, for example, I can use a newer version of Python that is installed in /usr/local/bin.
To do that, just add the following like to .bash_profile:
export PATH="/usr/local/bin:$PATH"
NOTE: this change will make any programs with the same name that you install on /usr/local/bin take precedence over what is in /usr/bin.