File tree Expand file tree Collapse file tree 2 files changed +13
-1
lines changed
Expand file tree Collapse file tree 2 files changed +13
-1
lines changed Original file line number Diff line number Diff line change @@ -46,7 +46,14 @@ func (f *Feature) FromV1beta1(feature v1beta1.GrowthbookFeature) *Feature {
4646 f .Tags = feature .Spec .Tags
4747 f .DefaultValue = feature .Spec .DefaultValue
4848 f .ValueType = FeatureValueType (feature .Spec .ValueType )
49- f .Environments = nil
49+
50+ if f .Environments == nil {
51+ f .Environments = []string {}
52+ }
53+
54+ if f .Tags == nil {
55+ f .Tags = []string {}
56+ }
5057
5158 f .EnvironmentSettings = make (map [string ]EnvironmentSetting )
5259 for _ , env := range feature .Spec .Environments {
Original file line number Diff line number Diff line change @@ -37,6 +37,11 @@ func (s *SDKConnection) FromV1beta1(client v1beta1.GrowthbookClient) *SDKConnect
3737 s .IncludeVisualExperiments = client .Spec .IncludeVisualExperiments
3838 s .IncludeDraftExperiments = client .Spec .IncludeDraftExperiments
3939 s .IncludeExperimentNames = client .Spec .IncludeExperimentNames
40+
41+ if s .Languages == nil {
42+ s .Languages = []string {}
43+ }
44+
4045 return s
4146}
4247
You can’t perform that action at this time.
0 commit comments