From 1938865132fa14784be1699e5773e6feb575e5c5 Mon Sep 17 00:00:00 2001 From: Igor Ilic Date: Fri, 7 Apr 2023 23:09:02 +0200 Subject: [PATCH] QoL: fix typos and comments --- composer.json | 2 +- sample/index.php | 2 +- src/DIContainer.php | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/composer.json b/composer.json index 305c16c..3f6a1b9 100644 --- a/composer.json +++ b/composer.json @@ -33,7 +33,7 @@ } ], "require": { - "php" : ">=8.1", + "php" : ">=8.0", "ext-json" : "*", "ext-mbstring" : "*" }, diff --git a/sample/index.php b/sample/index.php index 40882dc..6af7708 100644 --- a/sample/index.php +++ b/sample/index.php @@ -209,5 +209,5 @@ function has_roles(string $allowedRoles) : void { } function test_middleware() : void { - + //Do something } \ No newline at end of file diff --git a/src/DIContainer.php b/src/DIContainer.php index e2479cb..89daa5d 100644 --- a/src/DIContainer.php +++ b/src/DIContainer.php @@ -52,7 +52,7 @@ public static function get(string $class, array $arguments = []) : array { $parameters = $constructor->getParameters(); - if ( is_null($parameters) || count($parameters) === 0 ) { + if ( count($parameters) === 0 ) { return $arguments; }