Improve username handling