EionRobb / purple-mattermost

A libpurple/Pidgin plugin for Mattermost
GNU General Public License v3.0
93 stars 23 forks source link

code displayed incorrectly: includes html tags #98

Open wom-bat opened 5 years ago

wom-bat commented 5 years ago

When a post includes code marked in the input with three backticks, it is displayed as a verbatim dump including the < br/ > and &gt; etc., tags that mattermost puts in. Example:

` ` `
uint64_t x;
return (uint16_t) x>>48;
` ` `

displays as:

<br>uint64_t x;<br>return (uint16_t) x &gt;&gt; 48;<br>
wom-bat commented 5 years ago

Looks like this is only for markdown generated by the plugin; people using a real mattermost client or the web interface can create code snippets that display correctly.

wom-bat commented 5 years ago

More info: Sending the code sends it verbatim to the server; but it is displayed incorrectly in the local puidgin instance only; other clients see the result correctly.

wom-bat commented 5 years ago

What's more if I 'edit' a post in the webbrowser interface, the result is displayed correctly in Pidgin.