Fixed forest-wallet set-default failing when the keystore has no default entry.#7087
Fixed forest-wallet set-default failing when the keystore has no default entry.#7087sudo-shashank wants to merge 3 commits into
forest-wallet set-default failing when the keystore has no default entry.#7087Conversation
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
✨ Simplify code
Comment |
Codecov Report❌ Patch coverage is Additional details and impacted files
... and 9 files with indirect coverage changes Continue to review full report in Codecov by Sentry.
🚀 New features to boost your workflow:
|
| } | ||
|
|
||
| /// Set the default key to the key identified by `addr`. | ||
| pub fn set_default(addr: &Address, keystore: &mut KeyStore) -> Result<(), Error> { |
There was a problem hiding this comment.
why does this need to be a free function?
There was a problem hiding this comment.
matches other methods in this module like get_default, list_addrs, remove_key etc
Summary of changes
Changes introduced in this pull request:
Reference issue to close (if applicable)
Closes #7018
Other information and links
Change checklist
Outside contributions
Summary by CodeRabbit
Bug Fixes
forest-wallet set-defaultcommand now handles cases where the keystore lacks a default entry, resolving issue#7018.Refactor