use duck-typing instead of type field

This commit is contained in:
Hazel Koehler 2024-05-03 00:52:47 -04:00
parent 13c69cb8ad
commit ccdf069cdd

View file

@ -448,7 +448,7 @@ export class ApNoteService {
const limit = promiseLimit<MiDriveFile>(2);
const filePromises = attachments
.filter(attach => toArray(attach.type).includes('Image'))
.filter(attach => typeof(attach.url) === 'string')
.map(attach => (
limit(() => this.apImageService.resolveImage(actor, {
...attach,