add IEmailService to the DI container (#154)

This commit is contained in:
Aaron Po
2026-02-19 22:04:30 -05:00
committed by GitHub
parent 2cad88e3f6
commit c5683df4b6

View File

@@ -15,6 +15,7 @@ using Microsoft.AspNetCore.Mvc;
using Microsoft.AspNetCore.Mvc.Filters;
using Service.Auth;
using Service.UserManagement.User;
using Service.Emails;
var builder = WebApplication.CreateBuilder(args);
@@ -62,6 +63,7 @@ builder.Services.AddScoped<ITokenInfrastructure, JwtInfrastructure>();
builder.Services.AddScoped<IPasswordInfrastructure, Argon2Infrastructure>();
builder.Services.AddScoped<IEmailProvider, SmtpEmailProvider>();
builder.Services.AddScoped<IEmailTemplateProvider, EmailTemplateProvider>();
builder.Services.AddScoped<IEmailService, EmailService>();
// Register the exception filter
builder.Services.AddScoped<GlobalExceptionFilter>();