Skip to content

Commit

Permalink
fix: De-dup pubkey conversion of cli-wallet param (#11948)
Browse files Browse the repository at this point in the history
The public key option has a
[function](https://github.com/AztecProtocol/aztec-packages/blob/master/yarn-project/cli-wallet/src/cmds/index.ts#L157)
that interpreted the string to a public key, and this conversion was
attempted
[again](https://github.com/AztecProtocol/aztec-packages/blob/master/yarn-project/cli-wallet/src/cmds/index.ts#L209)
on the PublicKeys type.

TODO: Fix the comments of the cli wallet and `parsePublicKey` to better
reflect that publicKey is not actually singular and a concatenation of
all the contract's keys and is only used circumspectly when decrypting
(but directly for nullifying)

---------

Co-authored-by: esau <[email protected]>
  • Loading branch information
jzaki and sklppy88 authored Feb 12, 2025
1 parent 90b9fbf commit 5529871
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions yarn-project/cli-wallet/src/cmds/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ import { createCompatibleClient } from '@aztec/aztec.js/rpc';
import { TxHash } from '@aztec/aztec.js/tx_hash';
import { createAztecNodeClient } from '@aztec/circuit-types';
import { GasFees } from '@aztec/circuits.js';
import { PublicKeys } from '@aztec/circuits.js/types';
import {
ETHEREUM_HOST,
PRIVATE_KEY,
Expand Down Expand Up @@ -206,7 +205,7 @@ export function injectCommands(
wallet,
artifactPath,
json,
publicKey ? PublicKeys.fromString(publicKey) : undefined,
publicKey,
args,
salt,
typeof init === 'string' ? init : undefined,
Expand Down

0 comments on commit 5529871

Please sign in to comment.