mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-10-26 16:46:12 +01:00
fix: #13254, configurable ap content prune
This commit is contained in:
@@ -564,7 +564,7 @@ Notes.prune = async () => {
|
|||||||
*/
|
*/
|
||||||
winston.info('[notes/prune] Starting scheduled pruning of topics');
|
winston.info('[notes/prune] Starting scheduled pruning of topics');
|
||||||
const start = '-inf';
|
const start = '-inf';
|
||||||
const stop = Date.now() - (1000 * 60 * 60 * 24 * 30); // 30 days; todo: make configurable?
|
const stop = Date.now() - (1000 * 60 * 60 * 24 * meta.config.activitypubContentPruneDays);
|
||||||
let tids = await db.getSortedSetRangeByScore('cid:-1:tids', 0, -1, start, stop);
|
let tids = await db.getSortedSetRangeByScore('cid:-1:tids', 0, -1, start, stop);
|
||||||
|
|
||||||
winston.info(`[notes/prune] Found ${tids.length} topics older than 30 days (since last activity).`);
|
winston.info(`[notes/prune] Found ${tids.length} topics older than 30 days (since last activity).`);
|
||||||
|
|||||||
Reference in New Issue
Block a user