added handling of errCode for create and login of users