Lesson 5: encrypt.js #5216
Answered
by
alymurtazamemon
Aishwaria8786
asked this question in
Q&A
-
I am facing a problem. Don't know what to do.
In terminal it is showing:
What should I do now? |
Beta Was this translation helpful? Give feedback.
Answered by
alymurtazamemon
Apr 3, 2023
Replies: 2 comments 4 replies
-
@Aishwaria8786 I am also not familiar with this error. Can you leave your repo link so I can test it locally? |
Beta Was this translation helpful? Give feedback.
3 replies
Answer selected by
alymurtazamemon
-
In ethers ver 6, wallet.encrypt no need to to specify the private key. In your code, you just need to get rid of process.env.PRIVATE_KEY, like this: const encryptedJsonKey = await wallet.encrypt(process.env.PRIVATE_KEY_PASSWORD); |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
@Aishwaria8786 I am also not familiar with this error. Can you leave your repo link so I can test it locally?