Skip to content

Commit

Permalink
Change condition to assert $pieces[1] is set for Psalm
Browse files Browse the repository at this point in the history
  • Loading branch information
trowski committed Feb 8, 2023
1 parent 4ca6895 commit 66680c6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Cookie/ResponseCookie.php
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ public static function fromHeader(string $string): ?self
$pieces = \array_map('trim', \explode('=', $part, 2));
$key = \strtolower($pieces[0]);

if (1 === \count($pieces)) {
if (\count($pieces) < 2) {
switch ($key) {
case 'secure':
$meta = $meta->withSecure();
Expand Down

0 comments on commit 66680c6

Please sign in to comment.