Skip to content

Commit

Permalink
chore: remove uneeded code
Browse files Browse the repository at this point in the history
`Input` is initialized with fields populated and at the end of the
function the fields are updated again with the same value

Signed-off-by: budimanjojo <[email protected]>
Signed-off-by: Andrey Smirnov <[email protected]>
  • Loading branch information
budimanjojo authored and smira committed Nov 1, 2023
1 parent cbe6e76 commit 3703041
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions pkg/machinery/config/generate/generate.go
Original file line number Diff line number Diff line change
Expand Up @@ -61,11 +61,7 @@ func (in *Input) GetAPIServerSANs() []string {

// NewInput prepares a new Input struct to perform machine config generation.
func NewInput(clustername, endpoint, kubernetesVersion string, opts ...Option) (*Input, error) {
input := &Input{
ClusterName: clustername,
ControlPlaneEndpoint: endpoint,
KubernetesVersion: kubernetesVersion,
}
input := &Input{}
input.Options = DefaultOptions()

for _, opt := range opts {
Expand Down

0 comments on commit 3703041

Please sign in to comment.