mirror of
https://github.com/flarum/framework.git
synced 2024-11-29 12:43:52 +08:00
info: Show base URL
This commit is contained in:
parent
96a40fd6ea
commit
5d88ad2431
|
@ -47,7 +47,10 @@ class Server extends AbstractServer
|
|||
];
|
||||
|
||||
foreach ($commands as $command) {
|
||||
$console->add($app->make($command));
|
||||
$console->add($app->make(
|
||||
$command,
|
||||
['config' => $app->make('flarum.config')]
|
||||
));
|
||||
}
|
||||
|
||||
return $console;
|
||||
|
|
|
@ -22,11 +22,18 @@ class InfoCommand extends AbstractCommand
|
|||
protected $extensions;
|
||||
|
||||
/**
|
||||
* @param ExtensionManager $extensions
|
||||
* @var array
|
||||
*/
|
||||
public function __construct(ExtensionManager $extensions)
|
||||
protected $config;
|
||||
|
||||
/**
|
||||
* @param ExtensionManager $extensions
|
||||
* @param array $config
|
||||
*/
|
||||
public function __construct(ExtensionManager $extensions, array $config)
|
||||
{
|
||||
$this->extensions = $extensions;
|
||||
$this->config = $config;
|
||||
|
||||
parent::__construct();
|
||||
}
|
||||
|
@ -57,5 +64,7 @@ class InfoCommand extends AbstractCommand
|
|||
|
||||
$this->info("EXT $name $version");
|
||||
}
|
||||
|
||||
$this->info('Base URL: '.$this->config['url']);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user