Frontend: Fixed note renote detection
This commit is contained in:
parent
7eb03d59fb
commit
10256c683c
|
@ -78,7 +78,7 @@ import * as os from "@/os";
|
|||
import { definePageMetadata } from "@/scripts/page-metadata";
|
||||
import { i18n } from "@/i18n";
|
||||
import { endpoints, packed } from "magnetar-common";
|
||||
import { magTransUsername } from "@/scripts-mag/mag-util";
|
||||
import { magIsRenote, magTransUsername } from "@/scripts-mag/mag-util";
|
||||
|
||||
const props = defineProps<{
|
||||
noteId: string;
|
||||
|
@ -133,11 +133,7 @@ function fetchNote() {
|
|||
)
|
||||
.then((res) => {
|
||||
note = res;
|
||||
isRenote =
|
||||
note.renoted_note_id != null &&
|
||||
note.text == null &&
|
||||
note.file_ids.length === 0 &&
|
||||
note.poll == null;
|
||||
isRenote = magIsRenote(note);
|
||||
appearNote = isRenote
|
||||
? (note.renoted_note as packed.PackNoteMaybeFull)
|
||||
: note;
|
||||
|
|
Loading…
Reference in New Issue