From e1e3c0e865126006ed91e585176af4db85f3ef1f Mon Sep 17 00:00:00 2001 From: Julien Robert Date: Fri, 9 Feb 2024 15:23:08 +0100 Subject: [PATCH] updates --- client/config/config.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/client/config/config.go b/client/config/config.go index 097be5b68bf..efe65bd34ec 100644 --- a/client/config/config.go +++ b/client/config/config.go @@ -44,6 +44,7 @@ func ReadFromClientConfig(ctx client.Context) (client.Context, error) { // ReadDefaultValuesFromDefaultClientConfig reads default values from default client.toml file and updates them in client.Context // The client.toml is then discarded. func ReadDefaultValuesFromDefaultClientConfig(ctx client.Context, customClientTemplate string, customConfig interface{}) (client.Context, error) { + prevHomeDir := ctx.HomeDir dir, err := os.MkdirTemp("", "simapp") if err != nil { return ctx, fmt.Errorf("couldn't create temp dir: %w", err) @@ -56,7 +57,7 @@ func ReadDefaultValuesFromDefaultClientConfig(ctx client.Context, customClientTe return ctx, fmt.Errorf("couldn't create client config: %w", err) } - ctx.HomeDir = "" + ctx.HomeDir = prevHomeDir return ctx, nil }