From 09465619e53c9c0a04ee73cecc3fc2d87ee74d55 Mon Sep 17 00:00:00 2001 From: Mario Date: Sun, 28 Jan 2024 17:03:05 +0000 Subject: enable object cash by default, introduce system.cache_expire_days and default to 7, default system.default_expire_days to 30 and system.active_expire_days to 7 --- Zotlabs/Daemon/Cron.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'Zotlabs/Daemon/Cron.php') diff --git a/Zotlabs/Daemon/Cron.php b/Zotlabs/Daemon/Cron.php index caae0ce53..e0fa2d629 100644 --- a/Zotlabs/Daemon/Cron.php +++ b/Zotlabs/Daemon/Cron.php @@ -124,13 +124,13 @@ class Cron { $r = q("SELECT DISTINCT xchan, content FROM photo WHERE photo_usage = %d AND expires < %s - INTERVAL %s", intval(PHOTO_CACHE), db_utcnow(), - db_quoteinterval(get_config('system', 'active_expire_days', '30') . ' DAY') + db_quoteinterval(get_config('system', 'cache_expire_days', 7) . ' DAY') ); if ($r) { q("DELETE FROM photo WHERE photo_usage = %d AND expires < %s - INTERVAL %s", intval(PHOTO_CACHE), db_utcnow(), - db_quoteinterval(get_config('system', 'active_expire_days', '30') . ' DAY') + db_quoteinterval(get_config('system', 'cache_expire_days', 7) . ' DAY') ); foreach ($r as $rr) { $file = dbunescbin($rr['content']); -- cgit v1.2.3