Passed
Push — master ( d57c11...8c6e4f )
by Joao
03:16 queued 36s
created

example.php (2 issues)

Upgrade to new PHP Analysis Engine

These results are based on our legacy PHP analysis, consider migrating to our new PHP analysis engine instead. Learn more

1
<?php
2
3
require "vendor/autoload.php";
4
5
// Create a connection URL (see below)
6
$connection = new \ByJG\Mail\MailConnection('protocol://username:password/smtpserver:port');
7
8
// Create the proper mailer based on the connection
9
$mailer = ByJG\Mail\Envelope::mailerFactory($connection);
0 ignored issues
show
The method mailerFactory() does not seem to exist on object<ByJG\Mail\Envelope>.

This check looks for calls to methods that do not seem to exist on a given type. It looks for the method on the type itself as well as in inherited classes or implemented interfaces.

This is most likely a typographical error or the method has been renamed.

Loading history...
10
11
// Create the email envelope
12
$envelope = new ByJG\Mail\Envelope();
13
$envelope->setFrom('[email protected]', 'John Doe');
14
$envelope->addTo('[email protected]');
15
$envelope->setSubject('Email Subject');
16
$envelope->setBody('html text body');
17
18
// The the email with the selected mailer.
19
$envelope->send($mailer);
0 ignored issues
show
The method send() does not seem to exist on object<ByJG\Mail\Envelope>.

This check looks for calls to methods that do not seem to exist on a given type. It looks for the method on the type itself as well as in inherited classes or implemented interfaces.

This is most likely a typographical error or the method has been renamed.

Loading history...
20
21