Skip to content

Conversation

@Fahl-Design
Copy link
Contributor

Bug

When a request was made but Content-Type header was set,
and an other normal exception is thrown

normal exception is not displayed because:

Trace

Fatal error: Uncaught TypeError: explode(): Argument #2 ($string) must be of type string, null given in /var/www/html/vendor/codeception/lib-innerbrowser/src/Codeception/Lib/InnerBrowser.php:101
Stack trace:
#0 /var/www/html/vendor/codeception/lib-innerbrowser/src/Codeception/Lib/InnerBrowser.php(101): explode(';', NULL)
#1 /var/www/html/vendor/codeception/codeception/src/Codeception/Subscriber/Module.php(77): Codeception\Lib\InnerBrowser->_failed(Object(Codeception\Test\Cest), Object(PHPUnit\Framework\ExceptionWrapper))

- always use casting to string to hit more cases

Co-authored-by: Gustavo Nieves <64917965+TavoNiievez@users.noreply.github.com>
@TavoNiievez TavoNiievez merged commit 879872d into Codeception:master Dec 21, 2021
@Fahl-Design Fahl-Design deleted the fix_handling_for_missing_content_type_header branch December 21, 2021 10:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants