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

Escape prefix value in hasBasename #607

Closed
wants to merge 3 commits into from

Conversation

a-neumann
Copy link

fix: hasBasename handles search and additional special characters correctly

escape the ? [, ] and | character before using it in the regexp instantiation

w33ble and others added 3 commits July 3, 2018 14:23
including failing tests when using a search param in a basename
escape the ? character before using it in the regexp instantiation
@a-neumann
Copy link
Author

@w33ble thanks a lot for creating the issue #604 and writing the tests! I created a PR based on your changes.

@a-neumann a-neumann changed the title Escape prefix value in hasBasename #604 Escape prefix value in hasBasename Jul 18, 2018
@a-neumann
Copy link
Author

a-neumann commented Jul 25, 2018

Using escape-string-regexp instead will be a more comprehensive solution.

@a-neumann a-neumann closed this Jul 25, 2018
@lock lock bot locked as resolved and limited conversation to collaborators Sep 23, 2018
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.

None yet

2 participants