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
merged 1 commit into from
May 15, 2019

Conversation

shadoWalker89
Copy link
Contributor

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
@shadoWalker89 shadoWalker89 deleted the patch-3 branch May 15, 2019 13:14
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