Bug: Double-Quoted Strings get reduced to Single-Quoted Strings in Config
Closed this issue · 4 comments
UberPilot commented
What is the issue that you see?
What steps can be done to repeat the issue on a test server?
- Install Towny and TownyFlight.
- Set
pluginPrefix: "&3Towny &7\u00bb &f"
- Reload the plugin or restart the server.
- Notice the new prefix, displaying the unicode right-pointing double angle quotation mark in the prefix.
pluginPrefix
will turn intopluginPrefix: '&3Towny &7� &f'
in the config, with � being the replacement (0xFFFD) character.- Reload the plugin or restart the server again.
- Notice the new prefix, displaying the unicode replacement character.
What is supposed to happen instead?
pluginPrefix
should remain double-quoted and display unicode characters.
Versions/Files
Towny Version (use '/towny v' in game): 0.96.0.1
TownyFlight Version: 1.5.7
Link to TownyFlight config.yml (errored): https://pastebin.com/4j9SFNmY
Link to TownyFlight config.yml (ideal): https://pastebin.com/sii2Sw9w
LlmDl commented
Does it do anything differently when you use the » instead of \u00bb in the file?
UberPilot commented
No, it doesn't. It still gets replaced to the same string from step 5 above.
UberPilot commented
Turns out that this was a pretty trivial fix. I've created a pull request that will solve this.
LlmDl commented
Looks like we went to take care of this at pretty much the exact same time. Thanks though.