diff --git a/web/hooks/useGetHFRepoData.ts b/web/hooks/useGetHFRepoData.ts index 45f979fbde..d14458854a 100644 --- a/web/hooks/useGetHFRepoData.ts +++ b/web/hooks/useGetHFRepoData.ts @@ -20,7 +20,9 @@ export const useGetHFRepoData = () => { const data = await res.json() setRepoData(data) } catch (err) { - setFetchError(err as Error) + setFetchError( + Error("The repo does not exist or you don't have access to it.") + ) } setLoading(false) } diff --git a/web/screens/ExploreModels/HuggingFaceRepoDataLoadedModal/index.tsx b/web/screens/ExploreModels/HuggingFaceRepoDataLoadedModal/index.tsx index c4e9131bc0..32284ede52 100644 --- a/web/screens/ExploreModels/HuggingFaceRepoDataLoadedModal/index.tsx +++ b/web/screens/ExploreModels/HuggingFaceRepoDataLoadedModal/index.tsx @@ -53,7 +53,7 @@ export const HuggingFaceRepoDataLoadedModal = () => { ? '❌ This model is not supported!' : '✅ This model is supported!'}

- {repoData.tags.includes('gguf') ? ( + {repoData.tags?.includes('gguf') ? (

...But you can import it manually!

) : null} diff --git a/web/screens/ExploreModels/HuggingFaceSearchErrorModal/index.tsx b/web/screens/ExploreModels/HuggingFaceSearchErrorModal/index.tsx index 31c7d48d45..4cb58332bc 100644 --- a/web/screens/ExploreModels/HuggingFaceSearchErrorModal/index.tsx +++ b/web/screens/ExploreModels/HuggingFaceSearchErrorModal/index.tsx @@ -18,7 +18,7 @@ export const HuggingFaceSearchErrorModal = () => {

Error!

Fetch error

-

{fetchError.message}

+

{fetchError.message}