This commit is contained in:
@ -78,11 +78,11 @@ export async function createNote(value: any, resolver?: Resolver, silent = false
|
||||
}
|
||||
//#endergion
|
||||
|
||||
// 添付メディア
|
||||
// 添付ファイル
|
||||
// TODO: attachmentは必ずしもImageではない
|
||||
// TODO: attachmentは必ずしも配列ではない
|
||||
// Noteがsensitiveなら添付もsensitiveにする
|
||||
const media = note.attachment
|
||||
const files = note.attachment
|
||||
.map(attach => attach.sensitive = note.sensitive)
|
||||
? await Promise.all(note.attachment.map(x => resolveImage(actor, x)))
|
||||
: [];
|
||||
@ -100,7 +100,7 @@ export async function createNote(value: any, resolver?: Resolver, silent = false
|
||||
|
||||
return await post(actor, {
|
||||
createdAt: new Date(note.published),
|
||||
media,
|
||||
files: files,
|
||||
reply,
|
||||
renote: undefined,
|
||||
cw: note.summary,
|
||||
|
Reference in New Issue
Block a user