mirror of
https://github.com/friendica/friendica
synced 2025-04-23 23:10:10 +00:00
Bugfixings for Cache-Lock
- used wrong cachekey in set - therefore added an abstraction to avoid wrong key concatenation - forgot to increase the db-version to 1275
This commit is contained in:
parent
3be013361e
commit
34cea93a8b
7 changed files with 72 additions and 35 deletions
23
src/Core/Cache/AbstractCacheDriver.php
Normal file
23
src/Core/Cache/AbstractCacheDriver.php
Normal file
|
@ -0,0 +1,23 @@
|
|||
<?php
|
||||
|
||||
namespace Friendica\Core\Cache;
|
||||
use Friendica\BaseObject;
|
||||
|
||||
|
||||
/**
|
||||
* Abstract class for common used functions
|
||||
*
|
||||
* Class AbstractCacheDriver
|
||||
*
|
||||
* @package Friendica\Core\Cache
|
||||
*/
|
||||
abstract class AbstractCacheDriver extends BaseObject implements IMemoryCacheDriver
|
||||
{
|
||||
/**
|
||||
* @param string $key The original key
|
||||
* @return string The cache key used for the cache
|
||||
*/
|
||||
protected function getCacheKey($key) {
|
||||
return self::getApp()->get_hostname() . ":" . $key;
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue