[COMMAND] Fix 'bin/console doctrine:database:create' by only loading defaults if we have a connection

This commit is contained in:
Hugo Sales 2020-08-13 01:47:14 +00:00 committed by Hugo Sales
parent e2960aebcb
commit fd7e06bf18
1 changed files with 3 additions and 1 deletions

View File

@ -132,7 +132,9 @@ class GNUsocial implements EventSubscriberInterface
Mailer::setMailer($this->mailer);
Router::setRouter($this->router, $this->url_generator);
DefaultSettings::setDefaults();
if (isset($_ENV['HTTPS']) || isset($_ENV['HTTP_HOST'])) {
DefaultSettings::setDefaults();
}
Cache::setupCache();