From 0e0ac8d2b38b5c683c7ba5b5c0400fa0908fb55c Mon Sep 17 00:00:00 2001 From: Zaptoss Date: Wed, 10 Jul 2024 16:16:23 +0300 Subject: [PATCH] Rename request type --- ...ntegrations@geo-points-svc@v1@public@event_types@{name}.yaml | 2 +- internal/service/router.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/spec/paths/integrations@geo-points-svc@v1@public@event_types@{name}.yaml b/docs/spec/paths/integrations@geo-points-svc@v1@public@event_types@{name}.yaml index 6bdfb3c..b17f4dc 100644 --- a/docs/spec/paths/integrations@geo-points-svc@v1@public@event_types@{name}.yaml +++ b/docs/spec/paths/integrations@geo-points-svc@v1@public@event_types@{name}.yaml @@ -31,7 +31,7 @@ get: 500: $ref: '#/components/responses/internalError' -patch: +put: tags: - Event types summary: Update event type diff --git a/internal/service/router.go b/internal/service/router.go index d41dbf9..5615f2d 100644 --- a/internal/service/router.go +++ b/internal/service/router.go @@ -52,7 +52,7 @@ func Run(ctx context.Context, cfg config.Config) { r.Get("/", handlers.ListEventTypes) r.With(authMW).Post("/", handlers.CreateEventType) r.Get("/{name}", handlers.GetEventType) - r.With(authMW).Patch("/{name}", handlers.UpdateEventType) + r.With(authMW).Put("/{name}", handlers.UpdateEventType) }) }) // must be accessible only within the cluster