From a4994f53dd92e3ac4866d8dba3fdfac3a413d21b Mon Sep 17 00:00:00 2001 From: alireza Date: Wed, 23 Oct 2024 12:42:36 +0330 Subject: [PATCH] firx: RepositoryAlreadyExists add --- .../Core/DependencyInjection/RefitDependencyInjection.cs | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/Mohaymen.GiteaClient/Core/DependencyInjection/RefitDependencyInjection.cs b/Mohaymen.GiteaClient/Core/DependencyInjection/RefitDependencyInjection.cs index ff0bf4d..7e4a9ea 100644 --- a/Mohaymen.GiteaClient/Core/DependencyInjection/RefitDependencyInjection.cs +++ b/Mohaymen.GiteaClient/Core/DependencyInjection/RefitDependencyInjection.cs @@ -37,10 +37,7 @@ public static IServiceCollection AddRefitClientTypes(this IServiceCollection ser { return null; } - if (httpResponseMessage.StatusCode == HttpStatusCode.Conflict) - { - throw new RepositoryAlreadyExistsException(await httpResponseMessage.Content.ReadAsStringAsync()); - } + throw new Exception(await httpResponseMessage.Content.ReadAsStringAsync()); } })