From 17922b5b5a0a073e4649d17dccfea1733c71ab60 Mon Sep 17 00:00:00 2001
From: ko_oler <kooler89@gmail.com>
Date: Wed, 12 Jul 2023 10:54:57 +0300
Subject: [PATCH] =?UTF-8?q?=D0=BF=D1=80=D0=B0=D0=B2=D0=BA=D0=B8=20=D0=BF?=
 =?UTF-8?q?=D0=BE=20=D0=9F=D0=A0?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

---
 pkg/setup/collection.go | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/pkg/setup/collection.go b/pkg/setup/collection.go
index 9d2e638d..4c247953 100644
--- a/pkg/setup/collection.go
+++ b/pkg/setup/collection.go
@@ -225,7 +225,11 @@ func (s *Setup) UninstallCollections(ctx context.Context) error {
 }
 
 func (s *Setup) UninstallCollection(ctx context.Context, c CollectionConfig) error {
-	if ok, err := c.DeleteFn(s, c.collection); ok && err == nil {
+	ok, err := c.DeleteFn(s, c.collection)
+	if err != nil {
+		return err
+	}
+	if ok {
 		if err = s.content.Collections.Delete(ctx, s.SpaceID, s.EnvironmentID, c.collection.ID); err != nil && !strings.Contains(err.Error(), collections.ErrNotFound.Error()) {
 			return err
 		}
-- 
GitLab