april / decklist

The code behind decklist.org, which generates DCI Registration Sheets.
https://decklist.org/
MIT License
44 stars 20 forks source link

Apostrophes are not handled correctly in invalid card names #55

Open KingSupernova31 opened 6 years ago

KingSupernova31 commented 6 years ago

If the user enters an unrecognized card name, any apostrophes will be rendered as their HTML code of "\'". (The "single right quote" character that some sites use is rendered properly.)

Nightfirecat commented 6 years ago

This line just needs to have its .replace(/'/g, '&#39;') removed. Thinking about it, it'd probably be safe to remove everything except the replacements for <, > and &... The replacements for ' and " may not be needed.