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

Corrects implode() usage and uses wraps ints in '' to satisfy PHP 7.4. #75

Merged
merged 1 commit into from
Apr 11, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
sudo: false
language: php
php:
- 7.1
- 7.2
- 7.3
- 7.4
cache:
directories:
- $HOME/.composer/cache
Expand Down
1 change: 1 addition & 0 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
],
"license": "MIT",
"require": {
"php": ">=7.1",
"typhonius/acquia-php-sdk-v2": "^2.0.0",
"typhonius/acquia-logstream": "^0.5",
"consolidation/robo": "^2",
Expand Down
6 changes: 4 additions & 2 deletions composer.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions src/Commands/DomainCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -79,8 +79,8 @@ public function domainInfo(OutputInterface $output, Domains $domainAdapter, $uui
$domain->hostname,
$domain->flags->active ? '✓' : '',
$domain->flags->dns_resolves ? '✓' : '',
implode($domain->ip_addresses, "\n"),
implode($domain->cnames, "\n"),
implode("\n", $domain->ip_addresses),
implode("\n", $domain->cnames),
],
]
);
Expand Down
2 changes: 1 addition & 1 deletion src/Commands/EnvironmentsCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ public function environmentList(Environments $environmentsAdapter, OutputInterfa
$environment->uuid,
$environment->name,
$environment->label,
implode($environment->domains, "\n"),
implode("\n", $environment->domains),
],
]
);
Expand Down
2 changes: 1 addition & 1 deletion src/Commands/LogForwardCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ public function logforwardInfo(
$this->say(sprintf('Expires at: %s', $logForward->credentials->certificate->expires_at));
$this->say(sprintf('Token: %s', $logForward->credentials->token));
$this->say(sprintf('Key: %s', $logForward->credentials->key));
$this->say(sprintf('Sources: %s%s', "\n", implode($logForward->sources, "\n")));
$this->say(sprintf('Sources: %s%s', "\n", implode("\n", $logForward->sources)));
$this->say(sprintf('Health: %s', $logForward->health->summary));
}
}
2 changes: 1 addition & 1 deletion src/Commands/SslCertificateCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ public function sslCertificateList(
[
$certificate->id,
$certificate->label,
implode($certificate->domains, "\n"),
implode("\n", $certificate->domains),
$certificate->expires_at,
$certificate->flags->active ? '✓' : '',
],
Expand Down
4 changes: 2 additions & 2 deletions tests/Commands/DbBackupCommandTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ public function dbBackupProvider()

return [
[
['database:backup:restore', 'devcloud:devcloud2', 'dev', 'dbName', 1234],
['database:backup:restore', 'devcloud:devcloud2', 'dev', 'dbName', '1234'],
'> Restoring backup 1234 to dbName on Dev' . PHP_EOL
],
[
Expand All @@ -117,7 +117,7 @@ public function dbBackupProvider()
$dbBackupList . PHP_EOL
],
[
['database:backup:link', 'devcloud:devcloud2', 'dev', 'dbName', 1234],
['database:backup:link', 'devcloud:devcloud2', 'dev', 'dbName', '1234'],
$dbLink . PHP_EOL
],
];
Expand Down
2 changes: 1 addition & 1 deletion tests/Commands/LogForwardCommandTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ public function logForwardProvider()
$listResponse . PHP_EOL
],
[
['lf:info', 'devcloud:devcloud2', 'dev', 1234],
['lf:info', 'devcloud:devcloud2', 'dev', '1234'],
$infoResponse . PHP_EOL,
]
];
Expand Down
2 changes: 1 addition & 1 deletion tests/Commands/SslCertificateCommandTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ public function sslCertificateProvider()
$listResponse . PHP_EOL
],
[
['ssl:info', 'devcloud:devcloud2', 'dev', 1234],
['ssl:info', 'devcloud:devcloud2', 'dev', '1234'],
$infoResponse . PHP_EOL,
]
];
Expand Down