fix(agent): check auto-approved skills env correctly (#5511)

* fix(agent): check auto-approved skills env correctly

* remove file

---------

Co-authored-by: Timothy Carambat <rambat1010@gmail.com>
This commit is contained in:
Chris Z 2026-04-29 00:29:46 +08:00 committed by GitHub
parent 2029f90b42
commit ae9960b8ba
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -9,7 +9,7 @@ const chalk = require("chalk");
* @returns {boolean} True if the skill is auto-approved, false otherwise * @returns {boolean} True if the skill is auto-approved, false otherwise
*/ */
function skillIsAutoApproved({ skillName }) { function skillIsAutoApproved({ skillName }) {
if ((!"AGENT_AUTO_APPROVED_SKILLS") in process.env) return false; if (!("AGENT_AUTO_APPROVED_SKILLS" in process.env)) return false;
const autoApprovedSkills = String(process.env.AGENT_AUTO_APPROVED_SKILLS) const autoApprovedSkills = String(process.env.AGENT_AUTO_APPROVED_SKILLS)
.split(",") .split(",")
.map((skill) => skill.trim()) .map((skill) => skill.trim())