From 07b3f0c31632660087b078e090bae709387ad5b8 Mon Sep 17 00:00:00 2001 From: MGatner Date: Sun, 16 May 2021 19:53:37 +0000 Subject: [PATCH] Alias conflict --- system/Cache/Handlers/WincacheHandler.php | 4 ++-- system/Config/BaseService.php | 6 +++--- system/Database/Forge.php | 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/system/Cache/Handlers/WincacheHandler.php b/system/Cache/Handlers/WincacheHandler.php index f6ca9d8d5d40..dec5e8fab635 100644 --- a/system/Cache/Handlers/WincacheHandler.php +++ b/system/Cache/Handlers/WincacheHandler.php @@ -147,7 +147,7 @@ public function increment(string $key, int $offset = 1) $success = false; $value = wincache_ucache_inc($key, $offset, $success); - return ($success === true) ? $value : false; // @phpstan-ignore-line + return ($success === true) ? $value : false; } //-------------------------------------------------------------------- @@ -169,7 +169,7 @@ public function decrement(string $key, int $offset = 1) $success = false; $value = wincache_ucache_dec($key, $offset, $success); - return ($success === true) ? $value : false; // @phpstan-ignore-line + return ($success === true) ? $value : false; } //-------------------------------------------------------------------- diff --git a/system/Config/BaseService.php b/system/Config/BaseService.php index 5887eecdd411..d10f543e2369 100644 --- a/system/Config/BaseService.php +++ b/system/Config/BaseService.php @@ -65,7 +65,7 @@ use Config\Migrations; use Config\Modules; use Config\Pager as ConfigPager; -use Config\Services; +use Config\Services as AppServices; use Config\Toolbar as ConfigToolbar; use Config\Validation as ConfigValidation; use Config\View as ConfigView; @@ -85,7 +85,7 @@ * whereas with DI Containers there usually isn't a way for them to do this. * * Warning: To allow overrides by service providers do not use static calls, - * rather call out to \Config\Services instead. + * instead call out to \Config\Services (imported as AppServices). * * @see http://blog.ircmaxell.com/2015/11/simple-easy-risk-and-change.html * @see http://www.infoq.com/presentations/Simple-Made-Easy @@ -189,7 +189,7 @@ protected static function getSharedInstance(string $key, ...$params) // Make sure $getShared is false $params[] = false; - static::$instances[$key] = Services::$key(...$params); + static::$instances[$key] = AppServices::$key(...$params); } return static::$instances[$key]; diff --git a/system/Database/Forge.php b/system/Database/Forge.php index 3dda4be85a7e..a3bffff8a71a 100644 --- a/system/Database/Forge.php +++ b/system/Database/Forge.php @@ -243,7 +243,7 @@ public function createDatabase(string $dbName, bool $ifNotExists = false): bool { throw new DatabaseException('Unable to create the specified database.', 0, $e); } - // @phpstan-ignore-next-line + return false; // @codeCoverageIgnore } }