DOCS Update doc block for TestMailer::findEmail to reflect the new key names

This commit is contained in:
Robbie Averill 2017-09-06 16:10:55 +12:00
parent b270eee1b0
commit a4aa59bfdc
2 changed files with 5 additions and 5 deletions

View File

@ -537,8 +537,8 @@ class SapphireTest extends PHPUnit_Framework_TestCase implements TestOnly
* @param string $from
* @param string $subject
* @param string $content
* @return array Contains keys: 'type', 'to', 'from', 'subject','content', 'plainContent', 'attachedFiles',
* 'customHeaders', 'htmlContent', 'inlineImages'
* @return array|null Contains keys: 'Type', 'To', 'From', 'Subject', 'Content', 'PlainContent', 'AttachedFiles',
* 'HtmlContent'
*/
public function findEmail($to, $from = null, $subject = null, $content = null)
{

View File

@ -88,8 +88,8 @@ class TestMailer implements Mailer
* @param string $from
* @param string $subject
* @param string $content
* @return array Contains the keys: 'type', 'to', 'from', 'subject', 'content', 'plainContent', 'attachedFiles',
* 'customHeaders', 'htmlContent', 'inlineImages'
* @return array|null Contains keys: 'Type', 'To', 'From', 'Subject', 'Content', 'PlainContent', 'AttachedFiles',
* 'HtmlContent'
*/
public function findEmail($to, $from = null, $subject = null, $content = null)
{
@ -103,7 +103,7 @@ class TestMailer implements Mailer
foreach ($this->emailsSent as $email) {
$matched = true;
foreach (array('To','From','Subject','Content') as $field) {
foreach (array('To', 'From', 'Subject', 'Content') as $field) {
if ($value = $compare[$field]) {
if ($value[0] == '/') {
$matched = preg_match($value, $email[$field]);