From e011455a25aa272c7a708016d80036dff1069af7 Mon Sep 17 00:00:00 2001 From: naskya Date: Fri, 5 Jul 2024 23:45:58 +0900 Subject: [PATCH] fix (client): clicking remote instance ticker on unsigned UI causes an API error --- packages/client/src/components/note/MkNoteHeader.vue | 3 +++ 1 file changed, 3 insertions(+) diff --git a/packages/client/src/components/note/MkNoteHeader.vue b/packages/client/src/components/note/MkNoteHeader.vue index c5abfef6b2..1188f14575 100644 --- a/packages/client/src/components/note/MkNoteHeader.vue +++ b/packages/client/src/components/note/MkNoteHeader.vue @@ -58,6 +58,7 @@ import { userPage } from "@/filters/user"; import { i18n } from "@/i18n"; import { pageWindow } from "@/os"; import icon from "@/scripts/icon"; +import { me, isSignedIn } from "@/me"; const props = defineProps<{ note: entities.Note; @@ -71,6 +72,8 @@ const showTicker = function openServerInfo() { if (!props.canOpenServerInfo || !defaultStore.state.openServerInfo) return; + if (props.note.user.host != null && !isSignedIn(me)) return; + const instanceInfoUrl = props.note.user.host == null ? "/about"