feat: support multiple values for "image"
This commit is contained in:
parent
4b24cce2c5
commit
13c69cb8ad
|
@ -443,11 +443,12 @@ export class ApNoteService {
|
||||||
// 添付ファイル
|
// 添付ファイル
|
||||||
const attachments = toArray(note.attachment);
|
const attachments = toArray(note.attachment);
|
||||||
if (note.image)
|
if (note.image)
|
||||||
attachments.push(note.image);
|
for (const image of toArray(note.image))
|
||||||
|
attachments.push(image);
|
||||||
|
|
||||||
const limit = promiseLimit<MiDriveFile>(2);
|
const limit = promiseLimit<MiDriveFile>(2);
|
||||||
const filePromises = attachments
|
const filePromises = attachments
|
||||||
.filter(attach => toArray(attach.type)?.includes('Image'))
|
.filter(attach => toArray(attach.type).includes('Image'))
|
||||||
.map(attach => (
|
.map(attach => (
|
||||||
limit(() => this.apImageService.resolveImage(actor, {
|
limit(() => this.apImageService.resolveImage(actor, {
|
||||||
...attach,
|
...attach,
|
||||||
|
|
Loading…
Reference in New Issue