Modify authenticate_user method?