mirror of
https://github.com/GCMatters/hermes.git
synced 2026-02-04 13:40:13 +01:00
fix: rev db model, added missing entities and helper functions
This commit is contained in:
@@ -15,8 +15,8 @@ builder.Services.AddDbContext<ApplicationDbContext>(options =>
|
||||
builder.Services.AddDatabaseDeveloperPageExceptionFilter();
|
||||
|
||||
// Configure Identity
|
||||
builder.Services.AddDefaultIdentity<User>(options => options.SignIn.RequireConfirmedAccount = true)
|
||||
.AddEntityFrameworkStores<ApplicationDbContext>();
|
||||
//builder.Services.AddDefaultIdentity<User>(options => options.SignIn.RequireConfirmedAccount = true)
|
||||
// .AddEntityFrameworkStores<ApplicationDbContext>();
|
||||
|
||||
// API Services For Swagger
|
||||
builder.Services.AddEndpointsApiExplorer();
|
||||
@@ -25,6 +25,8 @@ builder.Services.AddSwaggerGen(c =>
|
||||
c.SwaggerDoc("v1", new Microsoft.OpenApi.Models.OpenApiInfo { Title = "hermes", Version = "v1" });
|
||||
});
|
||||
|
||||
builder.Services.AddScoped<GeneralUseHelpers>();
|
||||
|
||||
// Build Application
|
||||
var app = builder.Build();
|
||||
|
||||
@@ -45,7 +47,7 @@ app.UseHttpsRedirection(); // Redirects all HTTP requests to HTTPS
|
||||
app.UseDefaultFiles(); // Serves default files (index.html) if no specific file is requested
|
||||
app.UseStaticFiles(); // Serves static files(CSS, JS, Img) from the wwwroot folder.
|
||||
app.UseRouting(); // Enables routing to match incoming request to endpoints
|
||||
app.UseAuthorization();
|
||||
//app.UseAuthorization();
|
||||
|
||||
// Map Minimal API Endpoints
|
||||
app.MapEventsEndpoints();
|
||||
|
||||
Reference in New Issue
Block a user