mirror of https://github.com/langgenius/dify.git
fix: crash of tool authorization in agent
This commit is contained in:
parent
5f76975e12
commit
73825c59e4
|
|
@ -44,7 +44,7 @@ const AgentTools: FC = () => {
|
|||
const [currentTool, setCurrentTool] = useState<AgentToolWithMoreInfo>(null)
|
||||
const currentCollection = useMemo(() => {
|
||||
if (!currentTool) return null
|
||||
const collection = collectionList.find(collection => collection.id === currentTool?.provider_id.split('/').pop() && collection.type === currentTool?.provider_type)
|
||||
const collection = collectionList.find(collection => collection.id.split('/').pop() === currentTool?.provider_id.split('/').pop() && collection.type === currentTool?.provider_type)
|
||||
return collection
|
||||
}, [currentTool, collectionList])
|
||||
const [isShowSettingTool, setIsShowSettingTool] = useState(false)
|
||||
|
|
|
|||
Loading…
Reference in New Issue