Update .travis.yml and fix style (#414)

* Update .travis.yml

* syntax fix

* Apply fixes from StyleCI (#415)

* Syntax fix
This commit is contained in:
Tobias Nyholm 2017-12-01 20:55:29 +01:00 committed by GitHub
parent 1fd4f222e6
commit 6dfd2b5a18
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 7 additions and 7 deletions

View File

@ -11,6 +11,7 @@ php:
- 5.6
- 7.0
- 7.1
- 7.2
env:
- TEST_COMMAND="composer test-all"

View File

@ -83,19 +83,18 @@ class Domain extends HttpApi
*
* @return CreateResponse|array|ResponseInterface
*/
public function create($domain, $smtpPass = NULL, $spamAction = NULL, $wildcard = NULL)
public function create($domain, $smtpPass = null, $spamAction = null, $wildcard = null)
{
Assert::stringNotEmpty($domain);
$params = ['name'] = $domain;
// If at least smtpPass available, check for the fields spamAction wildcard
if(!empty($smtpPass) {
$params['name'] = $domain;
// If at least smtpPass available, check for the fields spamAction wildcard
if (!empty($smtpPass)) {
// TODO(sean.johnson): Extended spam filter input validation.
Assert::stringNotEmpty($spamAction);
Assert::boolean($wildcard);
$params['smtp_password'] = $smtpPass;
$params['spam_action'] = $spamAction;
}