mirror of
https://github.com/danny-avila/LibreChat.git
synced 2025-12-21 02:40:14 +01:00
🤖 refactor: Auto-validate IDs in Agent Query (#9555)
* 🤖 refactor: Auto-validate IDs in Agent Query
* chore: remove comments in useAgentToolPermissions
This commit is contained in:
parent
f3eca8c7a7
commit
f125f5bd32
6 changed files with 21 additions and 33 deletions
|
|
@ -47,11 +47,7 @@ export default function AgentPanel() {
|
|||
const { onSelect: onSelectAgent } = useSelectAgent();
|
||||
|
||||
const modelsQuery = useGetModelsQuery();
|
||||
|
||||
// Basic agent query for initial permission check
|
||||
const basicAgentQuery = useGetAgentByIdQuery(current_agent_id ?? '', {
|
||||
enabled: !!(current_agent_id ?? '') && current_agent_id !== Constants.EPHEMERAL_AGENT_ID,
|
||||
});
|
||||
const basicAgentQuery = useGetAgentByIdQuery(current_agent_id);
|
||||
|
||||
const { hasPermission, isLoading: permissionsLoading } = useResourcePermissions(
|
||||
ResourceType.AGENT,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue