add IdentifiableError.isRetryable to ensure that Identifiable Errors can still terminate a batch process

This commit is contained in:
Hazelnoot 2025-02-03 15:03:42 -05:00
parent 4a86ab6857
commit 3391c2414b
3 changed files with 16 additions and 2 deletions

View file

@ -520,7 +520,7 @@ export class DriveService {
// If usage limit exceeded
if (driveCapacity < usage + info.size) {
if (isLocalUser) {
throw new IdentifiableError('c6244ed2-a39a-4e1c-bf93-f0fbd7764fa6', 'No free space.');
throw new IdentifiableError('c6244ed2-a39a-4e1c-bf93-f0fbd7764fa6', 'No free space.', true);
}
await this.expireOldFile(await this.usersRepository.findOneByOrFail({ id: user.id }) as MiRemoteUser, driveCapacity - info.size);
}