Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[5.8] MailFake::failures() returns an empty array #28538

merged 1 commit into from May 15, 2019


None yet
2 participants
Copy link

commented May 15, 2019

When there is no failures, calling the failures() method on the real Mailer returns an empty array.
The fake mailer should do the same.

In my application i'm using the failures() method this way.

if (in_array($some_email, $mailer->failures())) {
    // Do something

When running my tests and using the Mail::fake() i get this error
ErrorException : in_array() expects parameter 2 to be array, null given

@taylorotwell taylorotwell merged commit 9d8aad9 into laravel:5.8 May 15, 2019

2 checks passed

continuous-integration/styleci/pr The analysis has passed
continuous-integration/travis-ci/pr The Travis CI build passed

@shadoWalker89 shadoWalker89 deleted the shadoWalker89:patch-3 branch May 15, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.