diff --git a/packages/app/src/components/quick-search/index.tsx b/packages/app/src/components/quick-search/index.tsx index 8d0d134a74..85753a59f0 100644 --- a/packages/app/src/components/quick-search/index.tsx +++ b/packages/app/src/components/quick-search/index.tsx @@ -27,11 +27,13 @@ export const QuickSearch = ({ open, onClose }: TransitionsModalProps) => { const [showCreatePage, setShowCreatePage] = useState(true); const { triggerQuickSearchModal } = useModal(); const { currentWorkspaceId, workspacesMeta } = useAppState(); - // Add ‘⌘+K’ shortcut keys as switches - const isPublic = workspacesMeta.find( - ({ id }) => id === currentWorkspaceId - )?.public; + const currentWorkspace = workspacesMeta.find( + meta => String(meta.id) === String(currentWorkspaceId) + ); + const isPublic = currentWorkspace?.public; + + // Add ‘⌘+K’ shortcut keys as switches useEffect(() => { const down = (e: KeyboardEvent) => { if (e.key === 'k' && e.metaKey) {