mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-06 14:20:44 +00:00
fix(qqbot): require auth for bot-approve
This commit is contained in:
@@ -0,0 +1,8 @@
|
||||
import { describe, expect, it } from "vitest";
|
||||
import { getFrameworkCommands } from "./slash-commands-impl.js";
|
||||
|
||||
describe("QQBot framework slash commands", () => {
|
||||
it("routes bot-approve through the auth-gated framework registry", () => {
|
||||
expect(getFrameworkCommands().map((command) => command.name)).toContain("bot-approve");
|
||||
});
|
||||
});
|
||||
@@ -746,6 +746,7 @@ export function registerApproveRuntimeGetter(
|
||||
registerCommand({
|
||||
name: "bot-approve",
|
||||
description: "管理命令执行审批配置",
|
||||
requireAuth: true,
|
||||
usage: [
|
||||
`/bot-approve 查看操作指引`,
|
||||
`/bot-approve on 开启审批(白名单模式,推荐)`,
|
||||
|
||||
Reference in New Issue
Block a user