Skip to content

Commit

Permalink
chore: display error message from response
Browse files Browse the repository at this point in the history
  • Loading branch information
louis-jan committed Nov 29, 2024
1 parent e23cc16 commit 79b29f7
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 5 deletions.
3 changes: 1 addition & 2 deletions web/containers/ModelSearch/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,7 @@ const ModelSearch = ({ onSearchLocal }: Props) => {
errMessage = err.message
}
toaster({
title: 'Oops, you may be rate limited, give it a bit more time',
description: errMessage,
title: errMessage,
type: 'error',
})
console.error(err)
Expand Down
4 changes: 1 addition & 3 deletions web/utils/huggingface.ts
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,7 @@ export const fetchHuggingFaceRepoData = async (
const data = response as HuggingFaceRepoData

if (data.tags.indexOf('gguf') === -1) {
throw new Error(
`${repoId} is not supported. Only GGUF models are supported.`
)
throw new Error(`Only GGUF models are currently supported.`)
}

// fetching file sizes
Expand Down

0 comments on commit 79b29f7

Please sign in to comment.