Skip to content

Improve error handling of generateSeedEthereum in design system shared #821

@georgewrmarshall

Description

@georgewrmarshall

https://github.com/MetaMask/metamask-design-system/pull/817/files#r2294831748

Bug: Ethereum Seed Generation Fails With Invalid Inputs

The generateSeedEthereum function can return NaN because parseInt receives an empty string (for short addresses like '0x') or invalid hexadecimal characters from the sliced address. This may cause issues for downstream icon generation expecting a numeric seed.

Fix in Cursor Fix in Web

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions