fix: uses to check if the tools are already loaded

This commit is contained in:
Yeuoly
2024-11-12 21:43:19 +08:00
parent 56bd0dedfe
commit 5828abcd62
2 changed files with 4 additions and 4 deletions

View File

@ -148,7 +148,7 @@ class ApiToolProviderController(ToolProviderController):
:param tenant_id: the tenant id
:return: the tools
"""
if self.tools is not None:
if len(self.tools) > 0:
return self.tools
tools: list[ApiTool] = []