aboutsummaryrefslogtreecommitdiffstats
path: root/Zotlabs/Lib
diff options
context:
space:
mode:
Diffstat (limited to 'Zotlabs/Lib')
-rw-r--r--Zotlabs/Lib/Cache.php14
1 files changed, 7 insertions, 7 deletions
diff --git a/Zotlabs/Lib/Cache.php b/Zotlabs/Lib/Cache.php
index a5052a183..60bf64611 100644
--- a/Zotlabs/Lib/Cache.php
+++ b/Zotlabs/Lib/Cache.php
@@ -5,17 +5,17 @@ namespace Zotlabs\Lib;
/**
* cache api
*/
-
+
class Cache {
-
+
/**
* @brief Returns cached content
- *
+ *
* @param string $key
* @param string $age in SQL format, default is '30 DAY'
* @return string
*/
-
+
public static function get($key, $age = '') {
$hash = hash('whirlpool',$key);
@@ -25,12 +25,12 @@ class Cache {
db_utcnow(),
db_quoteinterval(($age ? $age : get_config('system','object_cache_days', '30') . ' DAY'))
);
-
+
if ($r)
return $r[0]['v'];
return null;
}
-
+
public static function set($key,$value) {
$hash = hash('whirlpool',$key);
@@ -45,7 +45,7 @@ class Cache {
dbesc($hash));
}
else {
- q("INSERT INTO cache ( k, v, updated) VALUES ('%s','%s','%s')",
+ q("INSERT INTO cache (k, v, updated) VALUES ('%s', '%s', '%s')",
dbesc($hash),
dbesc($value),
dbesc(datetime_convert()));