diff --git a/src/StaticPHP/Runtime/Executor/WindowsCMakeExecutor.php b/src/StaticPHP/Runtime/Executor/WindowsCMakeExecutor.php index 1fb9c72b..9e097819 100644 --- a/src/StaticPHP/Runtime/Executor/WindowsCMakeExecutor.php +++ b/src/StaticPHP/Runtime/Executor/WindowsCMakeExecutor.php @@ -35,16 +35,10 @@ class WindowsCMakeExecutor extends Executor protected PackageInstaller $installer; - public function __construct(protected LibraryPackage $package, ?PackageBuilder $builder = null) + public function __construct(protected LibraryPackage $package) { parent::__construct($this->package); - if ($builder !== null) { - $this->builder = $builder; - } elseif (ApplicationContext::has(PackageBuilder::class)) { - $this->builder = ApplicationContext::get(PackageBuilder::class); - } else { - throw new SPCInternalException('PackageBuilder not found in ApplicationContext.'); - } + $this->builder = ApplicationContext::get(PackageBuilder::class); $this->installer = ApplicationContext::get(PackageInstaller::class); $this->initCmd();