Skip to content

Commit 47a8f58

Browse files
authored
Merge pull request #12 from induwara16/patch-1
Make Headers::get case insensitive (fix #11)
2 parents 2809c6e + aecb289 commit 47a8f58

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Headers.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ public static function all(bool $safeOutput = false): array
6464
*/
6565
public static function get($params, bool $safeOutput = false)
6666
{
67-
if (is_string($params)) return self::all($safeOutput)[$params] ?? null;
67+
if (is_string($params)) return array_change_key_case(self::all($safeOutput), CASE_LOWER)[strtolower($params)] ?? null;
6868

6969
$data = [];
7070
foreach ($params as $param) {

0 commit comments

Comments
 (0)