bebeboutik/modules/trustedshopsbbb/lib/TrustedShopsCache.php

22 lines
547 B
PHP
Raw Normal View History

2017-02-02 13:00:59 +01:00
<?php
class TrustedShopsCache{
const CONTROLLER_NAME = 'TrustedShopsCache';
const TTL = 86400; //2 days
public static function getReviewIndicatorCache($tsId)
{
if(class_exists('CacheRedis')){
return CacheRedis::getInstance()->get($tsId, self::CONTROLLER_NAME);
}
}
public static function setReviewIndicatorCache($ts_id, $content)
{
if(class_exists('CacheRedis')){
return CacheRedis::getInstance()->set($ts_id,self::CONTROLLER_NAME,$content,self::TTL);
}
}
}