From 17ce25b666988b996e70db51eb319d0fc2f453af Mon Sep 17 00:00:00 2001 From: ansuz Date: Wed, 12 Jun 2019 16:18:04 +0200 Subject: [PATCH] add a warning to delete-inactive, which we know has bugs --- scripts/delete-inactive.js | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/scripts/delete-inactive.js b/scripts/delete-inactive.js index 9dbfb0707..1cbe799d4 100644 --- a/scripts/delete-inactive.js +++ b/scripts/delete-inactive.js @@ -7,6 +7,14 @@ const config = require("../lib/load-config"); if (!config.inactiveTime || typeof(config.inactiveTime) !== "number") { return; } +/* Instead of this script you should probably use + evict-inactive.js which moves things to an archive directory + in case the data that would have been deleted turns out to be important. + it also handles removing that archived data after a set period of time + + it only works for channels at the moment, though, and nothing else. +*/ + let inactiveTime = +new Date() - (config.inactiveTime * 24 * 3600 * 1000); let inactiveConfig = { unpinned: true,