From 084221d5d4d11e89c35a83ad2f2869c958d25d7a Mon Sep 17 00:00:00 2001
From: hackerman <3372410+aeneasr@users.noreply.github.com>
Date: Thu, 2 Jan 2025 12:42:57 +0100
Subject: [PATCH] Revert "feat: expose api client hooks for dotnet (#389)"
(#392)
This reverts commit c446ce6f76c2b3d8dacf06efd40a75d159cb1bd2.
---
contrib/dotnet/ApiClientHooks.cs | 28 ----------------------------
scripts/generate.sh | 1 -
2 files changed, 29 deletions(-)
delete mode 100644 contrib/dotnet/ApiClientHooks.cs
diff --git a/contrib/dotnet/ApiClientHooks.cs b/contrib/dotnet/ApiClientHooks.cs
deleted file mode 100644
index 51dbb4149c..0000000000
--- a/contrib/dotnet/ApiClientHooks.cs
+++ /dev/null
@@ -1,28 +0,0 @@
-using RestSharp;
-using System;
-
-namespace Ory.Client.Client
-{
- public partial class ApiClient : ISynchronousClient, IAsynchronousClient
- {
- ///
- /// Hook to access the underlying RestRequest before the request is sent.
- ///
- public Action? RequestHook { get; set; }
-
- ///
- /// Hook to access the underlying RestRequest and RestResponse after the response is received.
- ///
- public Action? ResponseHook { get; set; }
-
- partial void InterceptRequest(RestRequest request)
- {
- RequestHook?.Invoke(request);
- }
-
- partial void InterceptResponse(RestRequest request, RestResponse response)
- {
- ResponseHook?.Invoke(request, response);
- }
- }
-}
\ No newline at end of file
diff --git a/scripts/generate.sh b/scripts/generate.sh
index d387c63026..1dbbf3ae71 100755
--- a/scripts/generate.sh
+++ b/scripts/generate.sh
@@ -232,7 +232,6 @@ dotnet () {
--git-host github.com \
-c ./config/client/dotnet.yml.proc.yml
cp "LICENSE" "clients/${PROJECT}/dotnet"
- cp "contrib/dotnet/ApiClientHooks.cs" "clients/${PROJECT}/dotnet/src/Ory.Client/Client"
}
dart () {