check for valid current user value in login script
Merge pull request #397 from niallkennedy/login-uid

check for valid current user value in login script