fixed check for user id