This commit is contained in:
2026-09-14 15:51:11 +02:00
parent ba5bc18b98
commit 22ffc3b51a
13 changed files with 3162 additions and 284 deletions
+11 -1
View File
@@ -1492,6 +1492,16 @@ const f0cklib = {
}
}
let subSizeNum = r.size;
if (!subSizeNum || isNaN(subSizeNum) || Number(subSizeNum) <= 0) {
try {
const bFile = path.join(cfg.paths.b, r.dest);
if (fs.existsSync(bFile)) {
subSizeNum = fs.statSync(bFile).size;
}
} catch (_) {}
}
let subTags = tagsBySubId.get(r.id) || [];
if (subTags.length === 0 && (r.order_index === 0 || idx === 0)) {
subTags = tags;
@@ -1505,7 +1515,7 @@ const f0cklib = {
src: `${cfg.websrv.paths.images}/${r.dest}`,
filename: r.dest,
mime: r.mime,
size: lib.formatSize(r.size),
size: lib.formatSize(subSizeNum),
width: r.width,
height: r.height,
checksum: r.checksum,