Skip to content

Commit

Permalink
chore: fmt
Browse files Browse the repository at this point in the history
  • Loading branch information
loks0n committed Jun 12, 2024
1 parent 60673ce commit c6236a7
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
9 changes: 7 additions & 2 deletions src/Orchestration/Adapter/DockerAPI.php
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,12 @@ class DockerAPI extends Adapter
{
/**
* Constructor
*
* @param string $username
* @param string $password
* @param string $email
*/
public function __construct(?string $username = null, ?string $password = null, ?string $email = null)
public function __construct(string $username = null, string $password = null, string $email = null)
{
if ($username && $password && $email) {
$this->registryAuth = base64_encode(json_encode([
Expand Down Expand Up @@ -261,10 +265,11 @@ public function networkDisconnect(string $container, string $network, bool $forc
/**
* Get usage stats of containers
*
* @param string $container
* @param array<string, string> $filters
* @return array<Stats>
*/
public function getStats(?string $container = null, array $filters = []): array
public function getStats(string $container = null, array $filters = []): array
{
// List ahead of time, since API does not allow listing all usage stats
$containerIds = [];
Expand Down
2 changes: 1 addition & 1 deletion src/Orchestration/Adapter/DockerCLI.php
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,7 @@ private function parseIOStats(string $stats)
foreach ($units as $unit => $value) {
if (\str_ends_with($inStr, $unit)) {
$inUnit = $unit;
}
}
if (\str_ends_with($outStr, $unit)) {
$outUnit = $unit;
}
Expand Down

0 comments on commit c6236a7

Please sign in to comment.