diff options
| author | Jake Mannens <jake@asger.xyz> | 2023-09-29 17:46:47 +1000 |
|---|---|---|
| committer | Jake Mannens <jake@asger.xyz> | 2023-09-29 17:57:21 +1000 |
| commit | e0cf80a5d0e2d6898b611892a331aa917b9370d9 (patch) | |
| tree | 75809891d57e687a246233f52feead273a1eca7d /Program.cs | |
| parent | c5ff0b57a12b605a5ae5ae8a92ce7a4e8eaec77a (diff) | |
Finalised security service
Diffstat (limited to 'Program.cs')
| -rw-r--r-- | Program.cs | 7 |
1 files changed, 5 insertions, 2 deletions
@@ -1,7 +1,8 @@ -using Microsoft.EntityFrameworkCore; -using System.Text.Json.Serialization; +using HyperBooru.PrincipalProviders; using HyperBooru.Services; using Microsoft.AspNetCore.Authentication.Cookies; +using Microsoft.EntityFrameworkCore; +using System.Text.Json.Serialization; namespace HyperBooru; @@ -21,6 +22,8 @@ public class Program { // Add our custom services builder.Services.AddSingleton<IConfigService, ConfigService>(); builder.Services.AddDbContextFactory<HBContext>(); + builder.Services.AddSingleton<IPrincipalProvider, LocalPrincipalProvider>(); + builder.Services.AddSingleton<ISecurityService, SecurityService>(); builder.Services.AddScoped<ISearchService, SearchService>(); builder.Services.AddScoped<ITagService, TagService>(); builder.Services.AddScoped<IMediaService, MediaService>(); |
