make sure validation errors in background update-featured are returned to the job queue

This commit is contained in:
Hazelnoot 2025-09-17 12:25:24 -04:00
parent 3c64fbc9a5
commit e81c8b075b
5 changed files with 62 additions and 17 deletions

View file

@ -48,7 +48,7 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
private readonly cacheService: CacheService,
) {
super(meta, paramDef, async (ps) => {
const user = await this.cacheService.findRemoteUserById(ps.userId);
const user = await this.cacheService.findRemoteUserById(ps.userId).catch(() => null);
if (!user) {
throw new ApiError(meta.errors.noSuchUser);