From e6e59badf9fc7615e166d50a78346597f5da3757 Mon Sep 17 00:00:00 2001 From: Nikolai Rodionov Date: Tue, 30 Apr 2024 10:30:21 +0200 Subject: [PATCH] Return the created env on create req --- internal/controllers/environments.go | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/internal/controllers/environments.go b/internal/controllers/environments.go index 6920daa..82a7d7e 100644 --- a/internal/controllers/environments.go +++ b/internal/controllers/environments.go @@ -204,19 +204,29 @@ func (env *Environemnt) Get(ctx context.Context) error { } if val, ok := res["SP_DESCRIPTION"]; ok { env.Data.Description = val + } else { + env.Data.Description = "" } if val, ok := res["SP_PROVIDER"]; ok { env.Data.Provider = val + } else { + env.Data.Provider = "" } if val, ok := res["SP_KUBERNETES"]; ok { env.Data.Kubernetes = val + } else { + env.Data.Kubernetes = "" } if val, ok := res["SP_SERVER_TYPE"]; ok { env.Data.ServerType = val + } else { + env.Data.ServerType = "" } if val, ok := res["SP_SERVER_LOCATION"]; ok { env.Data.Location = val + } else { + env.Data.Location = "" } return nil