diff --git a/app/services/ContentService.ts b/app/services/ContentService.ts index 5c09944..83abbc6 100644 --- a/app/services/ContentService.ts +++ b/app/services/ContentService.ts @@ -162,12 +162,14 @@ class ContentService { try { result = await this.applyProbe(task, probe) } catch (error: any) { - // Another probe of the release (its first volume, its par2) deleted it as garbage meanwhile: - // what this one found has nowhere to go (LOG.md 2026-10-08 (7)). - if (error.code === '23503' && !(await db.from('files').where('id', task.fileId).select('id').first())) { + // Another probe deleted a release this one writes to as garbage meanwhile (LOG.md 2026-10-08 (7)): + // the file's own release (nothing left to do), or one its par2 set joins (once more: the set + // then finds the release's files gone and makes its own). + if (error.code !== '23503') throw error + if (!(await db.from('files').where('id', task.fileId).select('id').first())) { return { named: 0, contentType: probe.contentType, garbage: 'deleted meanwhile' } } - throw error + result = await this.applyProbe(task, probe) } result.garbage = (await GarbageFilter.afterProbe(task.fileId, probe.contentType)) ?? undefined return result