Работа на новой архитектуре
This commit is contained in:
@@ -53,6 +53,8 @@ public sealed class MessagesController : ControllerBase
|
||||
}
|
||||
|
||||
[HttpPost("upload")]
|
||||
[DisableRequestSizeLimit]
|
||||
[RequestFormLimits(MultipartBodyLengthLimit = 10L * 1024 * 1024 * 1024)] // 10 GB limit for form body
|
||||
public async Task<IActionResult> UploadFile(IFormFile file, CancellationToken ct)
|
||||
{
|
||||
if (file == null || file.Length == 0)
|
||||
|
||||
@@ -174,11 +174,11 @@ using (var scope = app.Services.CreateScope())
|
||||
}
|
||||
|
||||
// Настройка конвейера запросов
|
||||
app.UseCors();
|
||||
|
||||
app.UseMiddleware<Knot.Shared.Infrastructure.Middleware.ExceptionHandlingMiddleware>();
|
||||
app.UseMiddleware<Knot.Shared.Infrastructure.Middleware.AdminAuthMiddleware>();
|
||||
|
||||
app.UseCors();
|
||||
|
||||
if (app.Environment.IsDevelopment())
|
||||
{
|
||||
app.UseSwagger();
|
||||
|
||||
Reference in New Issue
Block a user