mirror of
https://activitypub.software/TransFem-org/Sharkey.git
synced 2024-12-16 10:11:54 +01:00
52b94dbc4a
* fix: quote notes are rendered as pure renote * fix: filesが指定されてて空配列のときにQuote扱いされる * chore: isQuoteの仕様をmisc/is-quote.tsと揃える * docs: is-quote.tsの方にNoteCreateService.isQuoteのことを書いて更新忘れを防ぐ
12 lines
431 B
TypeScript
12 lines
431 B
TypeScript
/*
|
|
* SPDX-FileCopyrightText: syuilo and other misskey contributors
|
|
* SPDX-License-Identifier: AGPL-3.0-only
|
|
*/
|
|
|
|
import type { MiNote } from '@/models/Note.js';
|
|
|
|
// eslint-disable-next-line import/no-default-export
|
|
export default function(note: MiNote): boolean {
|
|
// sync with NoteCreateService.isQuote
|
|
return note.renoteId != null && (note.text != null || note.hasPoll || (note.fileIds != null && note.fileIds.length > 0));
|
|
}
|