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

Make sure autocomplete triggers are regex safe #10785

Merged
merged 1 commit into from
Oct 19, 2018

Conversation

notnownikki
Copy link
Member

@notnownikki notnownikki commented Oct 19, 2018

Description

Fixes: #10781

Make sure autocomplete triggers are made safe for use in regex.

How has this been tested?

Install and test the autocomplete example from #10781

Types of changes

Bug fix

Checklist:

  • My code is tested.
  • My code follows the WordPress code style.
  • My code follows the accessibility standards.
  • My code has proper inline documentation.

@notnownikki
Copy link
Member Author

@georgeh @mkaz If this is an acceptable fix, we might want to carry this as a patch until the next release.

@ellatrix
Copy link
Member

Tbh, I do not remember writing anything like this, but maybe I did. Others have collaborated on the Autocomplete component in the few-times-squashed 78d1254, but this may very well me my mistake, if so, apologies! :)

Copy link
Member

@ellatrix ellatrix left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good!

@notnownikki
Copy link
Member Author

Thanks for the review :) To be honest I just pinged you because 1) your name was on the merge, and 2) reviews from you are always appreciated!

@notnownikki notnownikki merged commit ab9b4a2 into master Oct 19, 2018
@youknowriad youknowriad added this to the 4.1 - UI freeze milestone Oct 19, 2018
@youknowriad youknowriad deleted the fix/regex-safe-autocomplete-triggers branch October 19, 2018 09:44
@mtias mtias added the [Feature] Rich Text Related to the Rich Text component that allows developers to render a contenteditable label Oct 19, 2018
antpb pushed a commit to antpb/gutenberg that referenced this pull request Oct 26, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Feature] Rich Text Related to the Rich Text component that allows developers to render a contenteditable
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Autocompleters crash if the trigger has special meaning in a regex
4 participants