mirror of
https://fastgit.cc/https://github.com/anomalyco/opencode
synced 2026-04-21 13:21:17 +08:00
core: prevent codesearch and websearch tools when webfetch permission is denied
This commit is contained in:
@@ -140,6 +140,8 @@ export namespace ToolRegistry {
|
||||
}
|
||||
if (agent.permission.webfetch === "deny") {
|
||||
result["webfetch"] = false
|
||||
result["codesearch"] = false
|
||||
result["websearch"] = false
|
||||
}
|
||||
|
||||
return result
|
||||
|
||||
Reference in New Issue
Block a user