Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Extension becomes unusable after trying to validate a specifically malformed string #1460

Closed
arthurgeron opened this issue Sep 7, 2024 · 0 comments · Fixed by #1459
Closed
Assignees
Labels
bug Something isn't working

Comments

@arthurgeron
Copy link
Contributor

What version of Wallet are you using?

0.27.0

What is happening?

Extension becomes unusable after trying to validate a specifically malformed string

CleanShot.2024-09-07.at.13.41.25.mp4

steps to reproduce

  • Open the extension
  • Click on the current Network name
  • Click at Add net network
  • Paste the following string and click Validate: https://fffffff:[email protected]/v1/graphql
  • Focus the field again and delete the : after https://fffffff

How it should behave?

Should report that the network is invalid.

What os are you seeing the problem on?

Mac/Apple Desktop

What browser?

Chrome

What is your browser version?

128.0.6613.114

@arthurgeron arthurgeron added the bug Something isn't working label Sep 7, 2024
@arthurgeron arthurgeron self-assigned this Sep 7, 2024
arthurgeron added a commit that referenced this issue Sep 9, 2024
…ork URL (#1459)

## Context
With the previous regular expression, trying to parse a specifically
malformed string would block the V8 thread (good catch @LuizAsFight!).
More info on the issue can be read about
[here](https://issues.chromium.org/issues/365066528).

## Changes
- Optimized expression
- Added named matching groups
- Moved regular expression to be a global, avoiding instantiating it at
the method's execution time

Closes #1460
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant