Skip to content

Commit

Permalink
Fixed issue Webklex#354
Browse files Browse the repository at this point in the history
Fixed the issue Webklex#354 by casting the key to string in the switch. Tested on over 100000 emails and over 100 accounts without any problem.
  • Loading branch information
shuergab authored Jan 24, 2023
1 parent 3addefa commit 6dd99f8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Header.php
Original file line number Diff line number Diff line change
Expand Up @@ -265,7 +265,7 @@ public function rfc822_parse_headers($raw_headers): object {
foreach ($headers as $key => $values) {
if (isset($imap_headers[$key])) continue;
$value = null;
switch ($key) {
switch ((string)$key) {
case 'from':
case 'to':
case 'cc':
Expand Down

0 comments on commit 6dd99f8

Please sign in to comment.