Skip to content

Commit

Permalink
Fix BaseConfig didn't load Registrar files properly
Browse files Browse the repository at this point in the history
  • Loading branch information
vibbow committed Apr 16, 2019
1 parent d2465a8 commit 97abf70
Showing 1 changed file with 9 additions and 2 deletions.
11 changes: 9 additions & 2 deletions system/Config/BaseConfig.php
Original file line number Diff line number Diff line change
Expand Up @@ -181,8 +181,15 @@ protected function registerProperties()

if (! static::$didDiscovery)
{
$locator = \Config\Services::locator();
static::$registrars = $locator->search('Config/Registrar.php');
$locator = \Config\Services::locator();
$registrarsFiles = $locator->search('Config/Registrar.php');

foreach ($registrarsFiles as $file)
{
$className = $locator->getClassname($file);
static::$registrars[] = new $className();
}

static::$didDiscovery = true;
}

Expand Down

0 comments on commit 97abf70

Please sign in to comment.