diff --git a/cli/config/configurator.go b/cli/config/configurator.go index f8523fc637..8e112c90dc 100644 --- a/cli/config/configurator.go +++ b/cli/config/configurator.go @@ -41,10 +41,10 @@ func (c Configurator) WithOnFinish(onFinish onFinishFn) Configurator { func (c Configurator) Start(ctx context.Context, prev Config, flags ConfigFlags) error { c.flags = flags var serverURL string - if prev.UIEndpoint != "" { - serverURL = prev.UIEndpoint - } else if flags.Endpoint != "" { + if flags.Endpoint != "" { serverURL = flags.Endpoint + } else if prev.UIEndpoint != "" { + serverURL = prev.UIEndpoint } else { path := "" if prev.ServerPath != nil { diff --git a/go.work.sum b/go.work.sum index 5ba68739dc..481badd06e 100644 --- a/go.work.sum +++ b/go.work.sum @@ -573,6 +573,7 @@ github.com/aws/aws-sdk-go-v2/service/s3 v1.16.1 h1:z+P3r4LrwdudLKBoEVWxIORrk4sVg github.com/aws/aws-sdk-go-v2/service/sso v1.4.2 h1:pZwkxZbspdqRGzddDB92bkZBoB7lg85sMRE7OqdB3V0= github.com/aws/aws-sdk-go-v2/service/sts v1.7.2 h1:ol2Y5DWqnJeKqNd8th7JWzBtqu63xpOfs1Is+n1t8/4= github.com/aws/smithy-go v1.8.0 h1:AEwwwXQZtUwP5Mz506FeXXrKBe0jA8gVM+1gEcSRooc= +github.com/benbjohnson/clock v1.3.0/go.mod h1:J11/hYXuz8f4ySSvYwY0FKfm+ezbsZBKZxNJlLklBHA= github.com/benbjohnson/immutable v0.2.1 h1:EVv7H1ju7cDg/a8HUF4hAH4DBrMJh6RWWFwq9JfoO9I= github.com/benbjohnson/tmpl v1.0.0 h1:T5QPGJD0W6JJxyEEAlVnX3co/IkUrfHen1/42nlgAHo= github.com/bgentry/speakeasy v0.1.0 h1:ByYyxL9InA1OWqxJqqp2A5pYHUrCiAL6K3J+LKSsQkY=