diff --git a/validator/node/node.go b/validator/node/node.go index 7ee3570ff..53b3637ab 100644 --- a/validator/node/node.go +++ b/validator/node/node.go @@ -79,11 +79,8 @@ func NewValidatorClient(cliCtx *cli.Context) (*ValidatorClient, error) { cmd.ConfigureValidator(cliCtx) featureconfig.ConfigureValidator(cliCtx) - keyManagerV1, err := selectV1Keymanager(cliCtx) - if err != nil { - return nil, err - } + var keyManagerV1 v1.KeyManager var keyManagerV2 v2.IKeymanager if featureconfig.Get().EnableAccountsV2 { walletDir := cliCtx.String(flags.WalletDirFlag.Name) @@ -105,6 +102,11 @@ func NewValidatorClient(cliCtx *cli.Context) (*ValidatorClient, error) { if err != nil { log.Fatalf("Could not read existing keymanager for wallet: %v", err) } + } else { + keyManagerV1, err = selectV1Keymanager(cliCtx) + if err != nil { + return nil, err + } } pubKeys, err := ExtractPublicKeysFromKeymanager(cliCtx, keyManagerV1, keyManagerV2)