From 5c27ce1a3a01337018db2778e2334c11ceb4e3f8 Mon Sep 17 00:00:00 2001 From: Maxim N Epikhin Date: Tue, 7 Dec 2021 21:28:23 +0300 Subject: [PATCH] =?UTF-8?q?=D0=98=D1=81=D0=BF=D1=80=D0=B0=D0=B2=D0=BB?= =?UTF-8?q?=D0=B5=D0=BD=D0=B0=20=D0=BE=D0=B1=D0=BB=D0=B0=D1=81=D1=82=D1=8C?= =?UTF-8?q?=20=D0=B2=D0=B8=D0=B4=D0=B8=D0=BC=D0=BE=D1=81=D1=82=D0=B8=20?= =?UTF-8?q?=D0=BF=D0=B5=D1=80=D0=B5=D0=BC=D0=B5=D0=BD=D0=BD=D0=BE=D0=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/Entity.php | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/Entity.php b/src/Entity.php index b5634d4..3529b9a 100644 --- a/src/Entity.php +++ b/src/Entity.php @@ -37,14 +37,14 @@ public static function getMapValueByKey(string $key) { throw new InvalidArgumentException("Ключ {$key} отсутствует."); } - return self::$map[$key]; + return static::$map[$key]; } /** * @inheritDoc */ public static function has(string $key): bool { - return array_key_exists($key, self::$map); + return array_key_exists($key, static::$map); } /** @@ -52,13 +52,13 @@ public static function has(string $key): bool { */ public static function getMap(string $key = ''): array { if (empty($key)) { - return self::$map; + return static::$map; } if (!self::has($key)) { throw new InvalidArgumentException("Ключ {$key} отсутствует."); } - return [$key => self::$map[$key]]; + return [$key => static::$map[$key]]; } -} \ No newline at end of file +}