mirror of
https://github.com/Ombi-app/Ombi.git
synced 2025-07-11 07:46:05 -07:00
Set the admin to have all claims
This commit is contained in:
parent
a679f1a6a1
commit
16bd4f5b71
4 changed files with 87 additions and 20 deletions
|
@ -35,6 +35,7 @@ using Nancy.Security;
|
|||
|
||||
using PlexRequests.Core;
|
||||
using PlexRequests.Core.SettingModels;
|
||||
using PlexRequests.Helpers;
|
||||
using PlexRequests.UI.Models;
|
||||
|
||||
namespace PlexRequests.UI.Modules
|
||||
|
@ -103,7 +104,7 @@ namespace PlexRequests.UI.Modules
|
|||
{
|
||||
return Context.GetRedirect(!string.IsNullOrEmpty(BaseUrl) ? $"~/{BaseUrl}/register?error=true" : "~/register?error=true");
|
||||
}
|
||||
var userId = UserMapper.CreateUser(username, Request.Form.Password, new[] { "Admin" });
|
||||
var userId = UserMapper.CreateAdmin(username, Request.Form.Password);
|
||||
Session[SessionKeys.UsernameKey] = username;
|
||||
return this.LoginAndRedirect((Guid)userId);
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue