summaryrefslogtreecommitdiffstats
path: root/system
diff options
context:
space:
mode:
authorGeorge Petculescu <gxgpet@gmail.com>2021-09-26 22:56:39 +0200
committerGeorge Petculescu <gxgpet@gmail.com>2021-10-04 15:36:25 +0200
commit9f6925398097a4f655827dc4030c82d435e27ae8 (patch)
treebd3598444f5fff4240ba0719043cd7c04587334a /system
parent4fa09ccaa80770ed11a2fdf6f1e28c5e14914be4 (diff)
Adds PHP 8 in Travis
Diffstat (limited to 'system')
-rw-r--r--system/core/Output.php9
1 files changed, 7 insertions, 2 deletions
diff --git a/system/core/Output.php b/system/core/Output.php
index c56aff4b0..a2397763d 100644
--- a/system/core/Output.php
+++ b/system/core/Output.php
@@ -299,10 +299,15 @@ class CI_Output {
*/
public function get_header($header)
{
+ // We only need [x][0] from our multi-dimensional array
+ $header_lines = array_map(function ($headers)
+ {
+ return array_shift($headers);
+ }, $this->headers);
+
// Combine headers already sent with our batched headers
$headers = array_merge(
- // We only need [x][0] from our multi-dimensional array
- array_map('array_shift', $this->headers),
+ $header_lines,
headers_list()
);