-
Notifications
You must be signed in to change notification settings - Fork 13
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
Add checks to clean XML reserved characters when used in page metadata #3
Conversation
Moved the sed replacement into a separate PR. It's a good fix, but it turned out to not be the problem here, so it deserves to be its own PR. |
tested and it works!! |
039c259
to
153ac6f
Compare
Time to merge in changes from upstream. Hopefully that doesn't break stuff after the disaster I inflicted on myself to fix my git blame... |
Added a fancy CI test to check and make sure we don't break this XML sanitisation down the line. Yay unit testing!! |
A user might want to use XML reserved characters in their page metadata, not realising that this would break the sitemap or RSS feed. This PR implements a cleaner function to ensure such characters are automatically replaced with escape codes at runtime.
Edit:
This PR also adds a new unit test to make sure that the sanitisation actually works so that we don't break it down the line.