Skip to content

Commit

Permalink
[#ests] - adjustments
Browse files Browse the repository at this point in the history
  • Loading branch information
niden committed Mar 11, 2024
1 parent e61d800 commit a6426f4
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
4 changes: 4 additions & 0 deletions src/Di/Di.php
Original file line number Diff line number Diff line change
Expand Up @@ -246,6 +246,10 @@ public function get(string $name, array $parameters = null): mixed
*/
public static function getDefault(): ?DiInterface
{
if (null === self::$defaultContainer) {
self::$defaultContainer = new self();
}

return self::$defaultContainer;
}

Expand Down
2 changes: 1 addition & 1 deletion src/Tag.php
Original file line number Diff line number Diff line change
Expand Up @@ -357,7 +357,7 @@ public static function friendlyTitle(
*
* @return DiInterface
*/
public static function getDI(): DiInterface
public static function getDI(): ?DiInterface
{
if (null === self::$container) {
self::$container = Di::getDefault();
Expand Down

0 comments on commit a6426f4

Please sign in to comment.