Skip to content

Commit

Permalink
Apply fixes from StyleCI
Browse files Browse the repository at this point in the history
  • Loading branch information
StyleCIBot committed Apr 14, 2024
1 parent 6871617 commit b8cae32
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 2 deletions.
10 changes: 9 additions & 1 deletion framework/core/src/Extension/Bisect.php
Original file line number Diff line number Diff line change
@@ -1,5 +1,12 @@
<?php

/*
* This file is part of Flarum.
*
* For detailed copyright and license information, please view the
* LICENSE file that was distributed with this source code.
*/

namespace Flarum\Extension;

use Closure;
Expand Down Expand Up @@ -68,6 +75,7 @@ protected function bisect(BisectState $state): ?array

if ($low > $high) {
$this->end();

return null;
}

Expand Down Expand Up @@ -98,7 +106,7 @@ protected function bisect(BisectState $state): ?array
return $this->foundIssue($relevantEnabled[0]);
}

if (count($relevantDisabled) === 1 && !$issue) {
if (count($relevantDisabled) === 1 && ! $issue) {
return $this->foundIssue($relevantDisabled[0]);
}

Expand Down
7 changes: 7 additions & 0 deletions framework/core/src/Extension/BisectState.php
Original file line number Diff line number Diff line change
@@ -1,5 +1,12 @@
<?php

/*
* This file is part of Flarum.
*
* For detailed copyright and license information, please view the
* LICENSE file that was distributed with this source code.
*/

namespace Flarum\Extension;

use Flarum\Settings\SettingsRepositoryInterface;
Expand Down
3 changes: 2 additions & 1 deletion framework/core/src/Extension/Console/BisectCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ public function handle(): int
$result = $this->bisect->checkIssueUsing(function (array $step) use (&$start) {
if (! $start) {
$this->output->writeln("<info>Continuing bisect... {$step['stepsLeft']} steps left</info>");
$this->output->writeln('<info>Issue is in one of: (' . implode(', ', $step['relevantEnabled']) . ') or (' . implode(', ', $step['relevantDisabled']) . ')</info>');
$this->output->writeln('<info>Issue is in one of: ('.implode(', ', $step['relevantEnabled']).') or ('.implode(', ', $step['relevantDisabled']).')</info>');
} else {
$start = false;
}
Expand All @@ -46,6 +46,7 @@ public function handle(): int

if (! $result) {
$this->output->writeln('<error>Could not find the extension causing the issue.</error>');

return Command::FAILURE;
}

Expand Down

0 comments on commit b8cae32

Please sign in to comment.