mirror of
https://github.com/Ombi-app/Ombi.git
synced 2025-07-30 11:38:32 -07:00
Fixed #2151
This commit is contained in:
parent
0ce9fb2df9
commit
a0dbd1c442
5 changed files with 20 additions and 15 deletions
|
@ -123,7 +123,23 @@ namespace Ombi.Store.Context
|
|||
{
|
||||
NormalizedName = OmbiRoles.RecievesNewsletter.ToUpper()
|
||||
});
|
||||
SaveChanges();
|
||||
}
|
||||
|
||||
// Make sure we have the API User
|
||||
var apiUserExists = Users.Any(x => x.UserName.Equals("Api", StringComparison.CurrentCultureIgnoreCase));
|
||||
if (!apiUserExists)
|
||||
{
|
||||
Users.Add(new OmbiUser
|
||||
{
|
||||
UserName = "Api",
|
||||
UserType = UserType.SystemUser,
|
||||
NormalizedUserName = "API",
|
||||
|
||||
});
|
||||
SaveChanges();
|
||||
}
|
||||
|
||||
//Check if templates exist
|
||||
var templates = NotificationTemplates.ToList();
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue