Skip to content

Commit

Permalink
keep same behaviour for stack version as before (empty if not set)
Browse files Browse the repository at this point in the history
  • Loading branch information
mrodm committed Aug 27, 2024
1 parent 4c2037e commit 6ced570
Showing 1 changed file with 4 additions and 8 deletions.
12 changes: 4 additions & 8 deletions internal/install/application_configuration.go
Original file line number Diff line number Diff line change
Expand Up @@ -220,19 +220,15 @@ func Configuration(options ...ConfigurationOption) (*ApplicationConfiguration, e
return nil, fmt.Errorf("can't unmarshal configuration file: %w", err)
}

configuration := ApplicationConfiguration{
c: c,
}
configOptions := configurationOptions{}
for _, option := range options {
option(&configOptions)
}

configuration.agentImageType = configOptions.agentImageType

configuration.stackVersion = DefaultStackVersion
if configOptions.stackVersion != "" {
configuration.stackVersion = configOptions.stackVersion
configuration := ApplicationConfiguration{
c: c,
agentImageType: configOptions.agentImageType,
stackVersion: configOptions.stackVersion,
}

return &configuration, nil
Expand Down

0 comments on commit 6ced570

Please sign in to comment.