Skip to content
This repository has been archived by the owner on Oct 19, 2024. It is now read-only.

fix: don't panic if hex str too short #2363

Merged
merged 1 commit into from
Apr 24, 2023

Conversation

mattsse
Copy link
Collaborator

@mattsse mattsse commented Apr 19, 2023

Motivation

LocalWallet::from_str actually panics if != 32 bytes

Closes foundry-rs/foundry#4772

Solution

add check and return error instead

PR Checklist

  • Added Tests
  • Added Documentation
  • Breaking changes

@prestwich prestwich merged commit d64e630 into gakonst:master Apr 24, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Panic when no privkey provided
2 participants