diff --git a/.version b/.version
index dbef21c..1490e44 100644
--- a/.version
+++ b/.version
@@ -1 +1 @@
-0.17.20.30
\ No newline at end of file
+0.17.20.32
\ No newline at end of file
diff --git a/NetinaShop.Api/AppSettings/Production/appsettings.Production.json b/NetinaShop.Api/AppSettings/Production/appsettings.Production.json
index 1c1342c..a8af061 100644
--- a/NetinaShop.Api/AppSettings/Production/appsettings.Production.json
+++ b/NetinaShop.Api/AppSettings/Production/appsettings.Production.json
@@ -17,8 +17,8 @@
"TaxesFee": 9
},
"SiteSettings": {
- "BaseUrl": "https://api.vesmook.com",
- "AdminPanelBaseUrl": "https://admin.vesmook.com",
+ "BaseUrl": "https://api.vesmeh.com",
+ "AdminPanelBaseUrl": "https://admin.vesmeh.com",
"KaveNegarApiKey": "3735494B4143727A794346457461576A2B4B6668414973424E333561505A694B",
"UserSetting": {
"Username": "09214802813",
diff --git a/NetinaShop.Api/Controller/SeedController.cs b/NetinaShop.Api/Controller/SeedController.cs
index 53d3ca4..3a611d8 100644
--- a/NetinaShop.Api/Controller/SeedController.cs
+++ b/NetinaShop.Api/Controller/SeedController.cs
@@ -9,17 +9,32 @@ public class SeedController : ICarterModule
var group = app.NewVersionedApi("Seed")
.MapGroup("api/seed");
- group.MapPost("categories", SeedCategoriesAsync)
+ group.MapGet("test1", () =>
+ {
+ return TypedResults.BadRequest(new ApiResult(false, ApiResultStatusCode.ServerError,
+ "Server Error 1 ( BAD REQUEST )"));
+ })
.WithDisplayName("SeedCategoriesAsync")
.HasApiVersion(1.0);
- group.MapPost("brands", SeedBrandsAsync)
- .WithDisplayName("SeedBrandsAsync")
- .HasApiVersion(1.0);
+ group.MapGet("test2", () =>
+ {
+ throw new Exception("Server Error 2 ( EXCEPTION THROWN )");
+ })
+ .WithDisplayName("SeedCategoriesAsync")
+ .HasApiVersion(1.0);
- group.MapPost("products",SeedProductsAsync)
- .WithDisplayName("SeedProductsAsync")
- .HasApiVersion(1.0);
+ //group.MapPost("categories", SeedCategoriesAsync)
+ // .WithDisplayName("SeedCategoriesAsync")
+ // .HasApiVersion(1.0);
+
+ //group.MapPost("brands", SeedBrandsAsync)
+ // .WithDisplayName("SeedBrandsAsync")
+ // .HasApiVersion(1.0);
+
+ //group.MapPost("products",SeedProductsAsync)
+ // .WithDisplayName("SeedProductsAsync")
+ // .HasApiVersion(1.0);
}
diff --git a/NetinaShop.Api/NetinaShop.Api.csproj b/NetinaShop.Api/NetinaShop.Api.csproj
index b1c3f25..9715b12 100644
--- a/NetinaShop.Api/NetinaShop.Api.csproj
+++ b/NetinaShop.Api/NetinaShop.Api.csproj
@@ -6,8 +6,8 @@
enable
true
Linux
- 0.17.20.30
- 0.17.20.30
+ 0.17.20.32
+ 0.17.20.32
diff --git a/NetinaShop.Api/WebFramework/MiddleWares/ExceptionHandlerMiddleware.cs b/NetinaShop.Api/WebFramework/MiddleWares/ExceptionHandlerMiddleware.cs
index 52314a0..6eab0d8 100644
--- a/NetinaShop.Api/WebFramework/MiddleWares/ExceptionHandlerMiddleware.cs
+++ b/NetinaShop.Api/WebFramework/MiddleWares/ExceptionHandlerMiddleware.cs
@@ -145,7 +145,7 @@ public class ExceptionHandlerMiddleware
Formatting = Formatting.Indented
});
- context.Response.StatusCode = (int)httpStatusCode;
+ context.Response.StatusCode = (int)HttpStatusCode.InternalServerError;
context.Response.ContentType = "application/json";
await context.Response.WriteAsJsonAsync(result);
}