Skip to content

Commit

Permalink
fix: $options are not saved in cache
Browse files Browse the repository at this point in the history
  • Loading branch information
kenjis committed Oct 12, 2023
1 parent 3f9b834 commit 272ebaf
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions system/Config/Factories.php
Original file line number Diff line number Diff line change
Expand Up @@ -502,12 +502,14 @@ public static function getComponentInstances(string $component): array
{
if (! isset(static::$aliases[$component])) {
return [
'options' => [],
'aliases' => [],
'instances' => [],
];
}

return [
'options' => static::$options[$component],
'aliases' => static::$aliases[$component],
'instances' => self::$instances[$component],
];
Expand All @@ -520,9 +522,11 @@ public static function getComponentInstances(string $component): array
*/
public static function setComponentInstances(string $component, array $data): void
{
static::$aliases[$component] = $data['aliases'];
self::$instances[$component] = $data['instances'];
unset(self::$updated[$component]);
static::$options[$component] = $data['options'];
static::$aliases[$component] = $data['aliases'];
static::$instances[$component] = $data['instances'];

unset(static::$updated[$component]);
}

/**
Expand Down

0 comments on commit 272ebaf

Please sign in to comment.