Kaynağa Gözat

Simplify and faster headers from Set-Cookie

Joanhey 6 yıl önce
ebeveyn
işleme
3edfb563f3
1 değiştirilmiş dosya ile 1 ekleme ve 3 silme
  1. 1 3
      Protocols/Http.php

+ 1 - 3
Protocols/Http.php

@@ -242,9 +242,7 @@ class Http
         // other headers
         foreach (HttpCache::$header as $key => $item) {
             if ('Set-Cookie' === $key && \is_array($item)) {
-                foreach ($item as $it) {
-                    $header .= $it . "\r\n";
-                }
+                $header .= \implode("\r\n", $item) . "\r\n";
             } else {
                 $header .= $item . "\r\n";
             }