From 24438a2a27dd7d4d51885e481f881d07f28b8004 Mon Sep 17 00:00:00 2001 From: Rodrigue Cloutier Date: Tue, 27 Aug 2024 09:58:51 -0400 Subject: [PATCH] Fix: Early exit when deleting label Allow status code 204 to be valid and not error on label delete --- pkg/confluence/api.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkg/confluence/api.go b/pkg/confluence/api.go index 6ede89e3..902dc7be 100644 --- a/pkg/confluence/api.go +++ b/pkg/confluence/api.go @@ -605,7 +605,7 @@ func (api *API) DeletePageLabel(page *PageInfo, label string) (*LabelInfo, error return nil, err } - if request.Raw.StatusCode != http.StatusOK { + if request.Raw.StatusCode != http.StatusOK && request.Raw.StatusCode != http.StatusNoContent { return nil, newErrorStatusNotOK(request) }