1
0
mirror of https://github.com/misskey-dev/misskey.git synced 2026-05-18 07:15:33 +02:00
Files
misskey/packages/backend/src/misc/is-quote.ts
2024-02-12 11:37:45 +09:00

13 lines
420 B
TypeScript

/*
* SPDX-FileCopyrightText: syuilo and misskey-project
* 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));
}