mirror of
https://github.com/flarum/framework.git
synced 2025-01-23 01:42:59 +08:00
Prevent notice if bootstrapping app in command line environment
This commit is contained in:
parent
327949495d
commit
5fcc504557
|
@ -164,7 +164,7 @@ class Application extends Container implements ApplicationContract
|
|||
public function url($path = null)
|
||||
{
|
||||
$config = $this->isInstalled() ? $this->make('flarum.config') : [];
|
||||
$url = array_get($config, 'url', $_SERVER['REQUEST_URI']);
|
||||
$url = array_get($config, 'url', array_get($_SERVER, 'REQUEST_URI'));
|
||||
|
||||
if (is_array($url)) {
|
||||
if (isset($url[$path])) {
|
||||
|
|
Loading…
Reference in New Issue
Block a user