From e08a9f61467591ae9d9dcc3b4736f30ab35ac540 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ng=C3=B4=20Qu=E1=BB=91c=20=C4=90=E1=BA=A1t?= Date: Wed, 25 Sep 2024 23:28:08 +0700 Subject: [PATCH] chore: Bisect should use `CacheClearCommand` in core instead (#4023) --- framework/core/src/Extension/Bisect.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/framework/core/src/Extension/Bisect.php b/framework/core/src/Extension/Bisect.php index a817fc9296..77b8ce1c92 100644 --- a/framework/core/src/Extension/Bisect.php +++ b/framework/core/src/Extension/Bisect.php @@ -10,7 +10,7 @@ namespace Flarum\Extension; use Closure; -use Composer\Command\ClearCacheCommand; +use Flarum\Foundation\Console\CacheClearCommand; use Flarum\Settings\SettingsRepositoryInterface; use RuntimeException; use Symfony\Component\Console\Input\ArrayInput; @@ -32,7 +32,7 @@ class Bisect public function __construct( protected ExtensionManager $extensions, protected SettingsRepositoryInterface $settings, - protected ClearCacheCommand $clearCache, + protected CacheClearCommand $cacheClear, ) { $this->state = BisectState::continueOrStart( $ids = $this->extensions->getEnabled(), @@ -139,12 +139,12 @@ public function end(): void $this->settings->set('extensions_enabled', json_encode($this->state->ids)); $this->settings->set('maintenance_mode', 'none'); $this->state->end(); - $this->clearCache->run(new ArrayInput([]), new NullOutput()); + $this->cacheClear->run(new ArrayInput([]), new NullOutput()); } protected function rotateExtensions(array $enabled): void { $this->settings->set('extensions_enabled', json_encode($enabled)); - $this->clearCache->run(new ArrayInput([]), new NullOutput()); + $this->cacheClear->run(new ArrayInput([]), new NullOutput()); } }