aboutsummaryrefslogtreecommitdiff
path: root/MediaBrowser.Api/UserService.cs
diff options
context:
space:
mode:
Diffstat (limited to 'MediaBrowser.Api/UserService.cs')
-rw-r--r--MediaBrowser.Api/UserService.cs17
1 files changed, 17 insertions, 0 deletions
diff --git a/MediaBrowser.Api/UserService.cs b/MediaBrowser.Api/UserService.cs
index df4bc06ba..b7a43c237 100644
--- a/MediaBrowser.Api/UserService.cs
+++ b/MediaBrowser.Api/UserService.cs
@@ -357,6 +357,23 @@ namespace MediaBrowser.Api
{
var auth = AuthorizationContext.GetAuthorizationInfo(Request);
+ if (string.IsNullOrWhiteSpace(auth.Client))
+ {
+ auth.Client = "Unknown app";
+ }
+ if (string.IsNullOrWhiteSpace(auth.Device))
+ {
+ auth.Device = "Unknown device";
+ }
+ if (string.IsNullOrWhiteSpace(auth.Version))
+ {
+ auth.Version = "Unknown version";
+ }
+ if (string.IsNullOrWhiteSpace(auth.DeviceId))
+ {
+ auth.DeviceId = "Unknown device id";
+ }
+
var result = _sessionMananger.AuthenticateNewSession(request.Username, request.Password, auth.Client, auth.Version,
auth.DeviceId, auth.Device, Request.RemoteIp, Request.IsLocal).Result;