mirror of https://github.com/langgenius/dify.git
fix: tool providers
This commit is contained in:
parent
2067092f52
commit
022eda9e8b
|
|
@ -36,7 +36,7 @@ const ProviderList = () => {
|
|||
const handleKeywordsChange = (value: string) => {
|
||||
setKeywords(value)
|
||||
}
|
||||
const { data: collectionList, refetch } = useAllToolProviders()
|
||||
const { data: collectionList = [], refetch } = useAllToolProviders()
|
||||
const filteredCollectionList = useMemo(() => {
|
||||
return collectionList.filter((collection) => {
|
||||
if (collection.type !== activeTab)
|
||||
|
|
|
|||
|
|
@ -18,7 +18,6 @@ export const useAllToolProviders = () => {
|
|||
return useQuery({
|
||||
queryKey: useAllToolProvidersKey,
|
||||
queryFn: () => get<Collection[]>('/workspaces/current/tool-providers'),
|
||||
initialData: [],
|
||||
})
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue