Explorar o código

Update conditional to be correct

Joshua Boniface %!s(int64=6) %!d(string=hai) anos
pai
achega
10f33b0273
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      MediaBrowser.Api/UserService.cs

+ 1 - 1
MediaBrowser.Api/UserService.cs

@@ -379,7 +379,7 @@ namespace MediaBrowser.Api
                 throw new ResourceNotFoundException("User not found");
             }
 
-            if (request.Pw == "")
+            if (!string.IsNullOrEmpty(request.Password) || string.IsNullOrEmpty(request.Pw))
             {
                 throw new MethodNotAllowedException("Hashed-only passwords are not valid for this API.");
             }