mirror of
https://github.com/laravel/valet.git
synced 2026-02-06 16:50:09 +01:00
Clean up NullWriter; drop legacy config check
This commit is contained in:
@@ -24,7 +24,6 @@
|
||||
|
||||
define('VALET_LOOPBACK', '127.0.0.1');
|
||||
define('VALET_SERVER_PATH', realpath(__DIR__.'/../../server.php'));
|
||||
define('VALET_LEGACY_HOME_PATH', $_SERVER['HOME'].'/.valet');
|
||||
|
||||
define('BREW_PREFIX', (new CommandLine())->runAsUser('printf $(brew --prefix)'));
|
||||
|
||||
@@ -34,9 +33,9 @@
|
||||
* Set or get a global console writer.
|
||||
*
|
||||
* @param null|OutputInterface $writer
|
||||
* @return OutputInterface Or anonymous class
|
||||
* @return OutputInterface|\NullWriter|null
|
||||
*/
|
||||
function writer(?OutputInterface $writer = null)/*: OutputInterface*/
|
||||
function writer(?OutputInterface $writer = null): OutputInterface|\NullWriter|null
|
||||
{
|
||||
$container = Container::getInstance();
|
||||
|
||||
@@ -48,7 +47,9 @@ function writer(?OutputInterface $writer = null)/*: OutputInterface*/
|
||||
return $container->make('writer');
|
||||
}
|
||||
|
||||
return Container::getInstance()->instance('writer', $writer);
|
||||
Container::getInstance()->instance('writer', $writer);
|
||||
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user