diff --git a/src/components/ContextMenu/instance.ts b/src/components/ContextMenu/instance.ts index 3e0cd165..862a09e6 100644 --- a/src/components/ContextMenu/instance.ts +++ b/src/components/ContextMenu/instance.ts @@ -29,7 +29,7 @@ const contextMenuInstance = ({ const { theme } = useTheme() const currentInstance = useSelector(getInstanceUrl) - const instance = status.uri && status.uri.split(new RegExp(/\/\/(.*?)\//))[1] + const instance = status?.uri && status.uri.split(new RegExp(/\/\/(.*?)\//))[1] const queryClient = useQueryClient() const mutation = useTimelineMutation({ diff --git a/src/components/ContextMenu/status.ts b/src/components/ContextMenu/status.ts index 5579a390..20f94fb6 100644 --- a/src/components/ContextMenu/status.ts +++ b/src/components/ContextMenu/status.ts @@ -70,7 +70,7 @@ const contextMenuStatus = ({ getInstanceAccount, (prev, next) => prev.id === next.id ) - const ownAccount = instanceAccount?.id === status.account.id + const ownAccount = instanceAccount?.id === status?.account.id if (ownAccount) { const accountMenuItems: ContextMenuAction[] = [