Merge pull request #797 from tidusjar/dev

#788 fixed!
pull/800/head
Jamie 8 years ago committed by GitHub
commit 485d7e9989

@ -232,7 +232,19 @@ namespace PlexRequests.UI.Modules
{
if (!settings.UserAuthentication)// Do not need to auth make admin use login screen for now TODO remove this
{
var perms = (Permissions)dbUser.Permissions;
if (dbUser != null)
{
var perms = (Permissions) dbUser.Permissions;
if (perms.HasFlag(Permissions.Administrator))
{
var uri = Linker.BuildRelativeUri(Context, "UserLoginIndex");
Session["TempMessage"] = Resources.UI.UserLogin_AdminUsePassword;
return Response.AsRedirect(uri.ToString());
}
}
if (plexLocal != null)
{
var perms = (Permissions)plexLocal.Permissions;
if (perms.HasFlag(Permissions.Administrator))
{
var uri = Linker.BuildRelativeUri(Context, "UserLoginIndex");
@ -241,6 +253,7 @@ namespace PlexRequests.UI.Modules
}
}
}
}
if(loginGuid == Guid.Empty && settings.UserAuthentication)
{

Loading…
Cancel
Save