From 645e930b3ee4b9524d22e0bb3cd3053787d7f437 Mon Sep 17 00:00:00 2001 From: "Serhii A. Hrytsenko" Date: Tue, 7 Feb 2023 14:19:35 -0500 Subject: [PATCH] Move API modules --- .../Systems/Controllers/AuthenticationModuleTests.cs | 2 +- .../HomeInventory.Web/{ => Modules}/ApiModule.cs | 2 +- .../HomeInventory.Web/{ => Modules}/AreaModule.cs | 2 +- .../{ => Modules}/AuthenticationModule.cs | 11 +---------- .../{ => Modules}/PermissionModule.cs | 2 +- 5 files changed, 5 insertions(+), 14 deletions(-) rename src/HomeInventory/HomeInventory.Web/{ => Modules}/ApiModule.cs (93%) rename src/HomeInventory/HomeInventory.Web/{ => Modules}/AreaModule.cs (90%) rename src/HomeInventory/HomeInventory.Web/{ => Modules}/AuthenticationModule.cs (75%) rename src/HomeInventory/HomeInventory.Web/{ => Modules}/PermissionModule.cs (92%) diff --git a/src/HomeInventory/HomeInventory.Tests/Systems/Controllers/AuthenticationModuleTests.cs b/src/HomeInventory/HomeInventory.Tests/Systems/Controllers/AuthenticationModuleTests.cs index 4f8d89054..d756576aa 100644 --- a/src/HomeInventory/HomeInventory.Tests/Systems/Controllers/AuthenticationModuleTests.cs +++ b/src/HomeInventory/HomeInventory.Tests/Systems/Controllers/AuthenticationModuleTests.cs @@ -10,7 +10,7 @@ using HomeInventory.Domain.Errors; using HomeInventory.Domain.ValueObjects; using HomeInventory.Tests.Helpers; -using HomeInventory.Web; +using HomeInventory.Web.Modules; using MediatR; using Microsoft.AspNetCore.Http; using Microsoft.AspNetCore.Http.HttpResults; diff --git a/src/HomeInventory/HomeInventory.Web/ApiModule.cs b/src/HomeInventory/HomeInventory.Web/Modules/ApiModule.cs similarity index 93% rename from src/HomeInventory/HomeInventory.Web/ApiModule.cs rename to src/HomeInventory/HomeInventory.Web/Modules/ApiModule.cs index f6f0c121f..1f35f228a 100644 --- a/src/HomeInventory/HomeInventory.Web/ApiModule.cs +++ b/src/HomeInventory/HomeInventory.Web/Modules/ApiModule.cs @@ -4,7 +4,7 @@ using Microsoft.AspNetCore.Builder; using Microsoft.AspNetCore.Routing; -namespace HomeInventory.Web; +namespace HomeInventory.Web.Modules; internal abstract class ApiModule : CarterModule { diff --git a/src/HomeInventory/HomeInventory.Web/AreaModule.cs b/src/HomeInventory/HomeInventory.Web/Modules/AreaModule.cs similarity index 90% rename from src/HomeInventory/HomeInventory.Web/AreaModule.cs rename to src/HomeInventory/HomeInventory.Web/Modules/AreaModule.cs index 795b1f4ed..b0024df77 100644 --- a/src/HomeInventory/HomeInventory.Web/AreaModule.cs +++ b/src/HomeInventory/HomeInventory.Web/Modules/AreaModule.cs @@ -3,7 +3,7 @@ using Microsoft.AspNetCore.Http; using Microsoft.AspNetCore.Routing; -namespace HomeInventory.Web; +namespace HomeInventory.Web.Modules; internal class AreaModule : ApiModule { diff --git a/src/HomeInventory/HomeInventory.Web/AuthenticationModule.cs b/src/HomeInventory/HomeInventory.Web/Modules/AuthenticationModule.cs similarity index 75% rename from src/HomeInventory/HomeInventory.Web/AuthenticationModule.cs rename to src/HomeInventory/HomeInventory.Web/Modules/AuthenticationModule.cs index 226b0d877..18b5b05de 100644 --- a/src/HomeInventory/HomeInventory.Web/AuthenticationModule.cs +++ b/src/HomeInventory/HomeInventory.Web/Modules/AuthenticationModule.cs @@ -1,13 +1,4 @@ -using HomeInventory.Application.Authentication.Commands.Register; -using HomeInventory.Application.Authentication.Queries.Authenticate; -using HomeInventory.Contracts; -using HomeInventory.Web.Authorization.Dynamic; -using Microsoft.AspNetCore.Builder; -using Microsoft.AspNetCore.Http; -using Microsoft.AspNetCore.Mvc; -using Microsoft.AspNetCore.Routing; - -namespace HomeInventory.Web; +namespace HomeInventory.Web.Modules; internal class AuthenticationModule : ApiModule { diff --git a/src/HomeInventory/HomeInventory.Web/PermissionModule.cs b/src/HomeInventory/HomeInventory.Web/Modules/PermissionModule.cs similarity index 92% rename from src/HomeInventory/HomeInventory.Web/PermissionModule.cs rename to src/HomeInventory/HomeInventory.Web/Modules/PermissionModule.cs index 6e6f1efeb..15ce9fbbd 100644 --- a/src/HomeInventory/HomeInventory.Web/PermissionModule.cs +++ b/src/HomeInventory/HomeInventory.Web/Modules/PermissionModule.cs @@ -4,7 +4,7 @@ using Microsoft.AspNetCore.Mvc; using Microsoft.AspNetCore.Routing; -namespace HomeInventory.Web; +namespace HomeInventory.Web.Modules; internal class PermissionModule : ApiModule {