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

Autosuggest: don't enqueue scripts if EP is indexing #2163

Merged
merged 1 commit into from
Apr 16, 2021

Conversation

felipeelia
Copy link
Member

Description of the Change

As stated in #2126, enqueueing Autosuggest scripts on the frontend while EP is indexing makes the autosuggest query to be empty, generating a TypeError: t.replace is not a function error. This PR adds a check, completely avoiding autosuggest to enqueue anything while EP is indexing.

Verification Process

Manual. Indexing with --nobulk and checking.

Applicable Issues

Fixes #2126

Changelog Entry

  • Autosuggest JavaScript is not loaded anymore when ElasticPress is indexing the content.

@felipeelia felipeelia added the qa label Apr 9, 2021
@felipeelia felipeelia added this to the 3.5.7 milestone Apr 9, 2021
@felipeelia felipeelia self-assigned this Apr 9, 2021
@felipeelia felipeelia modified the milestones: 3.5.7, 3.6.0 Apr 9, 2021
@brandwaffle brandwaffle merged commit a893302 into develop Apr 16, 2021
@brandwaffle brandwaffle deleted the fix/issue-2126 branch April 16, 2021 17:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Autosuggest: Uncaught (in promise) TypeError: t.replace is not a function
2 participants