Example #1
0
 /**
  * @return \Predis\Client|\PredisPhpdoc\Client
  */
 public static function getConnection()
 {
     if (is_null(self::$predis)) {
         $host = __Config::get('glizy.database.caching.redis');
         self::$predis = new Predis\Client($host ? $host : 'tcp://127.0.0.1:6379');
     }
     return self::$predis;
 }