Skip to content

Commit 5977d0c

Browse files
committed
fixed charset quotes #285
1 parent 792a7e8 commit 5977d0c

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/Http/Response.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -150,7 +150,8 @@ private function setContent($content)
150150
list($mime, $charset) = array_map('trim', explode(';', $this->contentType));
151151

152152
$this->contentType = $mime;
153-
$this->content = Utils::toUtf8($content, substr(strstr($charset, '='), 1));
153+
$charset = str_replace(['"', "'"], '', substr(strstr($charset, '='), 1));
154+
$this->content = Utils::toUtf8($content, trim($charset));
154155
}
155156
}
156157
}

0 commit comments

Comments
 (0)