Closed rbergman closed 10 years ago
Thank you, Robert, I'll merge this and include this in the next release. (I haven't catered for Unicode anywhere so far, but should probably do so at some stage.)
Thanks!
On Fri, May 16, 2014 at 10:29 AM, Pieter Rautenbach < notifications@github.com> wrote:
Merged #19https://github.com/parautenbach/TeamCity-HipChat-Notifier/pull/19 .
— Reply to this email directly or view it on GitHubhttps://github.com/parautenbach/TeamCity-HipChat-Notifier/pull/19#event-121984611 .
Without this change, room notification POSTs being sent to HipChat's REST API containing non-ASCII characters will fail to work, as a decoding issue prevents the notifications from being accepted. The JSON specification indicates that the application/json media-type should always be encoded in Unicode, but the single-arg StringEntity() constructor assumes the text/plain media type, which defaults to encoding as ISO-8859-1, as indicated in the HTTP specification.