From d1e37d0f23522be8de1e9ba84b35fc71ba68b17a Mon Sep 17 00:00:00 2001 From: Chris Marget Date: Tue, 30 Jul 2024 18:23:27 -0400 Subject: [PATCH] remove duplicate prefix on env var string --- apstra/provider.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apstra/provider.go b/apstra/provider.go index d8a79546..05bdfee2 100644 --- a/apstra/provider.go +++ b/apstra/provider.go @@ -231,7 +231,7 @@ func (o *providerConfig) fromEnv(_ context.Context, diags *diag.Diagnostics) { o.Experimental = types.BoolValue(v) } - if s, ok := os.LookupEnv(o.EnvVarPrefix.String() + o.EnvVarPrefix.String() + constants.EnvApiTimeout); ok && o.ApiTimeout.IsNull() { + if s, ok := os.LookupEnv(o.EnvVarPrefix.String() + constants.EnvApiTimeout); ok && o.ApiTimeout.IsNull() { v, err := strconv.ParseInt(s, 0, 64) if err != nil { diags.AddError(fmt.Sprintf("error parsing environment variable %q", o.EnvVarPrefix.String()+constants.EnvApiTimeout), err.Error())