From 75d6ace6e598d18e8b0567a737f94fb1d5cb26be Mon Sep 17 00:00:00 2001 From: Joe Ferguson Date: Fri, 26 Apr 2024 23:25:16 -0500 Subject: [PATCH] Update return types --- src/MakeCommand.php | 4 ++-- src/WslApplyFeatures.php | 4 ++-- src/WslCreateDatabaseCommand.php | 6 +++--- src/WslCreateSiteCommand.php | 4 ++-- 4 files changed, 9 insertions(+), 9 deletions(-) diff --git a/src/MakeCommand.php b/src/MakeCommand.php index e81f746d1..07b27b849 100644 --- a/src/MakeCommand.php +++ b/src/MakeCommand.php @@ -40,7 +40,7 @@ class MakeCommand extends Command * * @return void */ - protected function configure() + protected function configure(): void { $this->basePath = getcwd(); $this->projectName = basename($this->basePath); @@ -65,7 +65,7 @@ protected function configure() * @param \Symfony\Component\Console\Output\OutputInterface $output * @return int */ - public function execute(InputInterface $input, OutputInterface $output) + public function execute(InputInterface $input, OutputInterface $output): int { if (! $this->vagrantfileExists()) { $this->createVagrantfile(); diff --git a/src/WslApplyFeatures.php b/src/WslApplyFeatures.php index 76f80f232..851351b8d 100644 --- a/src/WslApplyFeatures.php +++ b/src/WslApplyFeatures.php @@ -47,7 +47,7 @@ class WslApplyFeatures extends Command * * @return void */ - protected function configure() + protected function configure(): void { $this->basePath = getcwd(); $this->projectName = basename($this->basePath); @@ -67,7 +67,7 @@ protected function configure() * @param OutputInterface $output * @return int */ - public function execute(InputInterface $input, OutputInterface $output) + public function execute(InputInterface $input, OutputInterface $output): int { // Grab the current settings or create an example configuration $format = $input->getOption('json') ? 'json' : 'yaml'; diff --git a/src/WslCreateDatabaseCommand.php b/src/WslCreateDatabaseCommand.php index 4448ef02e..0d64462f9 100644 --- a/src/WslCreateDatabaseCommand.php +++ b/src/WslCreateDatabaseCommand.php @@ -40,7 +40,7 @@ class WslCreateDatabaseCommand extends Command * * @return void */ - protected function configure() + protected function configure(): void { $this->basePath = getcwd(); $this->projectName = basename($this->basePath); @@ -59,7 +59,7 @@ protected function configure() * @param OutputInterface $output * @return int */ - public function execute(InputInterface $input, OutputInterface $output) + public function execute(InputInterface $input, OutputInterface $output): int { // Grab the current settings or create an example configuration $format = $input->getOption('json') ? 'json' : 'yaml'; @@ -85,7 +85,7 @@ public function execute(InputInterface $input, OutputInterface $output) * @param array $options * @return mixed */ - protected function parseSettingsFromFile(string $format, array $options) + protected function parseSettingsFromFile(string $format, array $options): mixed { $SettingsClass = ($format === 'json') ? JsonSettings::class : YamlSettings::class; $filename = __DIR__."/../Homestead.{$format}"; diff --git a/src/WslCreateSiteCommand.php b/src/WslCreateSiteCommand.php index 7bb2420c9..3a4c57e3e 100644 --- a/src/WslCreateSiteCommand.php +++ b/src/WslCreateSiteCommand.php @@ -40,7 +40,7 @@ class WslCreateSiteCommand extends Command * * @return void */ - protected function configure() + protected function configure(): void { $this->basePath = getcwd(); $this->projectName = basename($this->basePath); @@ -59,7 +59,7 @@ protected function configure() * @param OutputInterface $output * @return int */ - public function execute(InputInterface $input, OutputInterface $output) + public function execute(InputInterface $input, OutputInterface $output): int { // Remove any existing nginx sites $shell_output = shell_exec('sudo rm -rf /etc/nginx/sites-available/*');