We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 75abd1a commit 5955f8eCopy full SHA for 5955f8e
src/Symfony/Component/HttpFoundation/Response.php
@@ -224,11 +224,7 @@ public function prepare(Request $request)
224
$charset = $this->charset ?: 'UTF-8';
225
if (!$headers->has('Content-Type')) {
226
$headers->set('Content-Type', 'text/html; charset=' . $charset);
227
- } elseif (0 === stripos($headers->get('Content-Type'), 'text/') && false === stripos(
228
- $headers->get('Content-Type'),
229
- 'charset'
230
- )
231
- ) {
+ } elseif (0 === stripos($headers->get('Content-Type'), 'text/') && false === stripos($headers->get('Content-Type'), 'charset')) {
232
// add the charset
233
$headers->set('Content-Type', $headers->get('Content-Type') . '; charset=' . $charset);
234
}
0 commit comments