use 24 hours interval if the interval value (config.cache_control_interval) is set to over 1000. fixes cache control for older config.cache_control_interval values

このコミットが含まれているのは:
teddit 2022-01-29 23:53:51 +01:00
コミット 265c33fcd2
1個のファイルの変更12行の追加12行の削除

ファイルの表示

@ -20,8 +20,8 @@ module.exports.removeCacheFiles = function() {
if(config.cache_control) {
deleteStatic();
const hours = config.cache_control_interval;
if (hours < 1 || isNaN(hours)) {
let hours = config.cache_control_interval;
if (hours < 1 || hours > 10000 || isNaN(hours)) {
hours = 24;
}