Added checks for userName
Update