This is so frustrating. I have a bug to report and all I get after filling in a form is a link to the standard documentation and the community. Apparently they are not interested. "Talk to the hand". Anyway, if someone is looking, here's the problem.
You do not handle Unicode properly, you are hacking into the raw bytes of UTF-8 looking for ASCII characters. I experienced this in Confluence before and just now in Jira. Look at this review text:
This will display briefly and then, apparently in a crude post-processing effort, be turned into this:
It looks like someone is scanning the raw bytes for occurrences of ASCII characters ":(". Please get your encoding/decoding act together!
Recommended Learning For You
Level up your skills with Atlassian learning
Learning Path
Jira Administrator
Configure Jira Software, Jira Core, or Jira Service Management, including global settings, permissions, and schemes.
Managing Jira Projects Cloud
Learn to create and configure company-managed projects in Jira Software and partner effectively with Jira Admins.
Learning Path
Become an effective Jira Software Project Admin
This learning path is designed for team leaders who configure Jira Software projects to match a team's processes.