mirror of
https://github.com/friendica/friendica
synced 2025-04-26 00:30:12 +00:00
Move Cache::set() to DI::cache()->set()
This commit is contained in:
parent
3369dfaad9
commit
f68929633b
16 changed files with 25 additions and 39 deletions
|
@ -43,21 +43,4 @@ class Cache
|
|||
{
|
||||
return DI::cache()->get($key);
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief Put data in the cache according to the key
|
||||
*
|
||||
* The input $value can have multiple formats.
|
||||
*
|
||||
* @param string $key The key to the cached data
|
||||
* @param mixed $value The value that is about to be stored
|
||||
* @param integer $duration The cache lifespan
|
||||
*
|
||||
* @return bool
|
||||
* @throws \Exception
|
||||
*/
|
||||
public static function set($key, $value, $duration = CacheClass::MONTH)
|
||||
{
|
||||
return DI::cache()->set($key, $value, $duration);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue