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 error with setting startup.elements in configuration. (mathjax/MathJax#2371) #457

Merged
merged 1 commit into from
Apr 6, 2020

Conversation

dpvc
Copy link
Member

@dpvc dpvc commented Mar 19, 2020

This PR fixes an error that occurs when the startup configuration block includes an elements array (intended to restrict the typesetting to a collection of containers). WIthout this patch, MathJax throws an error. (The problem was that combineConfig() tried to merge a null value into the array, thinking it was an object, since typeof null === 'object').

It also turns out that the elements array was never used, even if specifying it didn't cause an error, so this also fixes that problem.

Finally, it simplifies the findMath render action, which was rather unpleasant to begin with.

Resolves issue mathjax/MathJax#2371.

@dpvc dpvc requested a review from zorkow March 19, 2020 16:52
@dpvc dpvc added this to the 3.0.2 milestone Mar 19, 2020
Copy link
Member

@zorkow zorkow left a comment

Choose a reason for hiding this comment

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

lgtm

@dpvc dpvc merged commit 5a527a4 into develop Apr 6, 2020
@dpvc dpvc deleted the issue2371 branch April 6, 2020 20:52
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