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

fix(hasProtocol): accept backslash too #122

Merged
merged 3 commits into from
Feb 16, 2023
Merged

fix(hasProtocol): accept backslash too #122

merged 3 commits into from
Feb 16, 2023

Conversation

pi0
Copy link
Member

@pi0 pi0 commented Feb 16, 2023

A URL like /\localhost or https:\/foo.com can also have protocol.

Notice we are already doing this normalization for parser (

input.replace(/\\/g, "/").match(/([^/:]+:)?\/\/([^/@]+@)?(.*)/) || []
)

@pi0 pi0 requested a review from danielroe February 16, 2023 17:47
@codecov
Copy link

codecov bot commented Feb 16, 2023

Codecov Report

Merging #122 (24536d5) into main (75a280c) will not change coverage.
The diff coverage is 100.00%.

@@           Coverage Diff           @@
##             main     #122   +/-   ##
=======================================
  Coverage   93.46%   93.46%           
=======================================
  Files           7        7           
  Lines         735      735           
  Branches      201      201           
=======================================
  Hits          687      687           
  Misses         48       48           
Impacted Files Coverage Δ
src/utils.ts 96.87% <100.00%> (ø)

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

@pi0 pi0 merged commit 31bc600 into main Feb 16, 2023
@pi0 pi0 deleted the fix/parse-backslash branch February 16, 2023 17:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants