File tree Expand file tree Collapse file tree 3 files changed +9
-5
lines changed Expand file tree Collapse file tree 3 files changed +9
-5
lines changed Original file line number Diff line number Diff line change @@ -37,11 +37,6 @@ enum Entrypoint {
3737 let app = Application ( env)
3838
3939 defer {
40- Task {
41- // This may not delete all because it's async
42- // Be sure to delete manually in dashboard
43- await deleteHooks ( app)
44- }
4540 app. shutdown ( )
4641 }
4742
Original file line number Diff line number Diff line change @@ -59,6 +59,10 @@ extension HookFunction {
5959 if error. containedIn ( [ . webhookError] ) && method == . POST {
6060 // swiftlint:disable:next line_length
6161 configuration. logger. warning ( " Hook Function: \" \( String ( describing: hookFunction) ) \" ; warning: \( error) ; on server: \( parseServerURLString) " )
62+ try await Self . method ( . DELETE,
63+ path,
64+ name: name,
65+ parseServerURLStrings: parseServerURLStrings)
6266 return try await Self . method ( . PUT,
6367 path,
6468 name: name,
Original file line number Diff line number Diff line change @@ -69,6 +69,11 @@ extension HookTrigger {
6969 if error. containedIn ( [ . webhookError] ) && method == . POST {
7070 // swiftlint:disable:next line_length
7171 configuration. logger. warning ( " Hook Trigger: \" \( String ( describing: hookTrigger) ) \" ; warning: \( error) ; on server: \( parseServerURLString) " )
72+ try await Self . method ( . DELETE,
73+ path,
74+ className: className,
75+ triggerName: triggerName,
76+ parseServerURLStrings: parseServerURLStrings)
7277 return try await Self . method ( . PUT,
7378 path,
7479 className: className,
You can’t perform that action at this time.
0 commit comments