Skip to content
This repository has been archived by the owner on Nov 14, 2019. It is now read-only.

change $arHeader['Content-type'] to array #21

Merged
merged 2 commits into from
Mar 1, 2017

Conversation

ickbinhier
Copy link
Contributor

with $arHeader['Content-type'] = ''; become i this errors:

PHP Warning: Illegal string offset 'type' in /lib/Cws/MailBounceHandler/Handler.php on line 915
PHP Warning: Illegal string offset 'report-type' in /lib/Cws/MailBounceHandler/Handler.php on line 918
PHP Warning: Illegal string offset 'boundary' in /lib/Cws/MailBounceHandler/Handler.php on line 918
PHP Warning: Illegal string offset 'type' in /lib/Cws/MailBounceHandler/Handler.php on line 1111
PHP Notice: Undefined index: first in /lib/Cws/MailBounceHandler/Handler.php on line 589

with $arHeader['Content-type'] = ''; become i this errors:

PHP Warning:  Illegal string offset 'type' in /lib/Cws/MailBounceHandler/Handler.php on line 915
PHP Warning:  Illegal string offset 'report-type' in /lib/Cws/MailBounceHandler/Handler.php on line 918
PHP Warning:  Illegal string offset 'boundary' in /lib/Cws/MailBounceHandler/Handler.php on line 918
PHP Warning:  Illegal string offset 'type' in /lib/Cws/MailBounceHandler/Handler.php on line 1111
PHP Notice:  Undefined index: first in /lib/Cws/MailBounceHandler/Handler.php on line 589
@@ -911,7 +911,7 @@ private static function parseHeader($arHeader)

if (isset($arHeader['Content-type'])) {
$ar_mr = explode(';', $arHeader['Content-type']);
$arHeader['Content-type'] = '';
$arHeader['Content-type'] = [];
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi,

Thanks for this PR but can you make a new commit by replacing [] with array() for backward compatibility

@crazy-max
Copy link
Owner

Hi,

Are you on PHP 7.x ?

@ickbinhier
Copy link
Contributor Author

PHP 7.1

@ickbinhier
Copy link
Contributor Author

i have changed to array()

@crazy-max crazy-max merged commit 282856b into crazy-max:master Mar 1, 2017
@ickbinhier ickbinhier deleted the patch-1 branch March 1, 2017 20:41
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants