From 091e790b83edd13435267dc5cff84c50b5440fc9 Mon Sep 17 00:00:00 2001 From: Philipinho <16838612+Philipinho@users.noreply.github.com> Date: Thu, 4 Sep 2025 14:22:40 -0700 Subject: [PATCH] fix attachment search in cloud --- apps/client/src/features/search/hooks/use-unified-search.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/apps/client/src/features/search/hooks/use-unified-search.ts b/apps/client/src/features/search/hooks/use-unified-search.ts index 2adccc25..dbc5563f 100644 --- a/apps/client/src/features/search/hooks/use-unified-search.ts +++ b/apps/client/src/features/search/hooks/use-unified-search.ts @@ -9,6 +9,7 @@ import { IPageSearchParams, } from "@/features/search/types/search.types"; import { useLicense } from "@/ee/hooks/use-license"; +import { isCloud } from "@/lib/config"; export type UnifiedSearchResult = IPageSearch | IAttachmentSearch; @@ -22,7 +23,7 @@ export function useUnifiedSearch( const { hasLicenseKey } = useLicense(); const isAttachmentSearch = - params.contentType === "attachment" && hasLicenseKey; + params.contentType === "attachment" && (isCloud() || hasLicenseKey); const searchType = isAttachmentSearch ? "attachment" : "page"; return useQuery({