Shopify/active_merchant — pull request #588 by aprofeit (2013-02-15 21:02:14+00:00)
Title: handle incorrectly encoded responses from barclays

#### Problem
When an order contains non-standard characters (normally in the customer's address and is normally accented characters) and is submitted to Barclays, they will send back an XML response flagged as UTF-8 but is actually ISO-8859-1. This causes parsers like REXML to raise an exception while parsing what it thinks is UTF-8.

Barclays has acknowledged this issue is on their end and informed us they have no plans on fixing it.

#### Changes
If a REXML::ParseException is raised, try converting the response from ISO-8859-1 to UTF-8.

#### Review
@ntalbott @jduff