1
0
mirror of https://github.com/guzzle/guzzle.git synced 2025-02-25 18:43:22 +01:00

Merge pull request #507 from checat/elseif

Avoid extra string test
This commit is contained in:
Michael Dowling 2013-12-30 11:11:53 -08:00
commit cc72f9beab

View File

@ -45,7 +45,7 @@ class DefaultResponseParser implements ResponseParserInterface
if ($result->getBody()) {
if (stripos($contentType, 'json') !== false) {
$result = $result->json();
} if (stripos($contentType, 'xml') !== false) {
} elseif (stripos($contentType, 'xml') !== false) {
$result = $result->xml();
}
}