Skip to content

Commit e7f1149

Browse files
committed
Fixed missing sprintf in CacheManager + Added Riak method annotation
1 parent 9fc5df3 commit e7f1149

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/phpFastCache/CacheManager.php

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,7 @@
3939
* @method static ExtendedCacheItemPoolInterface Mongodb() Mongodb($config = []) Return a driver "Mongodb" instance
4040
* @method static ExtendedCacheItemPoolInterface Predis() Predis($config = []) Return a driver "Predis" instance
4141
* @method static ExtendedCacheItemPoolInterface Redis() Redis($config = []) Return a driver "Pedis" instance
42+
* @method static ExtendedCacheItemPoolInterface Riak() Riak($config = []) Return a driver "Riak" instance
4243
* @method static ExtendedCacheItemPoolInterface Sqlite() Sqlite($config = []) Return a driver "Sqlite" instance
4344
* @method static ExtendedCacheItemPoolInterface Ssdb() Ssdb($config = []) Return a driver "Ssdb" instance
4445
* @method static ExtendedCacheItemPoolInterface Wincache() Wincache($config = []) Return a driver "Wincache" instance
@@ -230,7 +231,7 @@ public static function getInstance($driver = 'auto', array $config = [], $instan
230231
self::$instances[ $instance ] = new $class($config, $instance);
231232
self::$instances[ $instance ]->setEventManager(EventManager::getInstance());
232233
} else {
233-
throw new phpFastCacheDriverNotFoundException('The driver "%s" does not exists', $driver);
234+
throw new phpFastCacheDriverNotFoundException(sprintf('The driver "%s" does not exists', $driver));
234235
}
235236
} catch (phpFastCacheDriverCheckException $e) {
236237
if ($config[ 'fallback' ]) {
@@ -242,7 +243,7 @@ public static function getInstance($driver = 'auto', array $config = [], $instan
242243
self::$instances[ $instance ] = new $class($config, $instance);
243244
self::$instances[ $instance ]->setEventManager(EventManager::getInstance());
244245
} else {
245-
throw new phpFastCacheDriverNotFoundException('The driver "%s" does not exists', $driver);
246+
throw new phpFastCacheDriverNotFoundException(sprintf('The driver "%s" does not exists', $driver));
246247
}
247248
trigger_error(sprintf('The "%s" driver is unavailable at the moment, the fallback driver "%s" has been used instead.', $driver,
248249
$fallback), E_USER_WARNING);

0 commit comments

Comments
 (0)