chore: Enable "curly" rule to avoid single-statement if confusion/errors.

This commit is contained in:
cpojer
2026-01-31 16:19:20 +09:00
parent 009b16fab8
commit 5ceff756e1
1266 changed files with 27871 additions and 9393 deletions

View File

@@ -103,7 +103,9 @@ describe("Slack native command argument menus", () => {
registerSlackMonitorSlashCommands({ ctx: ctx as never, account: account as never });
const handler = commands.get("/usage");
if (!handler) throw new Error("Missing /usage handler");
if (!handler) {
throw new Error("Missing /usage handler");
}
const respond = vi.fn().mockResolvedValue(undefined);
const ack = vi.fn().mockResolvedValue(undefined);
@@ -132,7 +134,9 @@ describe("Slack native command argument menus", () => {
registerSlackMonitorSlashCommands({ ctx: ctx as never, account: account as never });
const handler = actions.get("openclaw_cmdarg");
if (!handler) throw new Error("Missing arg-menu action handler");
if (!handler) {
throw new Error("Missing arg-menu action handler");
}
const respond = vi.fn().mockResolvedValue(undefined);
await handler({
@@ -158,7 +162,9 @@ describe("Slack native command argument menus", () => {
registerSlackMonitorSlashCommands({ ctx: ctx as never, account: account as never });
const handler = actions.get("openclaw_cmdarg");
if (!handler) throw new Error("Missing arg-menu action handler");
if (!handler) {
throw new Error("Missing arg-menu action handler");
}
const respond = vi.fn().mockResolvedValue(undefined);
await handler({
@@ -186,7 +192,9 @@ describe("Slack native command argument menus", () => {
registerSlackMonitorSlashCommands({ ctx: ctx as never, account: account as never });
const handler = actions.get("openclaw_cmdarg");
if (!handler) throw new Error("Missing arg-menu action handler");
if (!handler) {
throw new Error("Missing arg-menu action handler");
}
await handler({
ack: vi.fn().mockResolvedValue(undefined),
@@ -208,7 +216,9 @@ describe("Slack native command argument menus", () => {
registerSlackMonitorSlashCommands({ ctx: ctx as never, account: account as never });
const handler = actions.get("openclaw_cmdarg");
if (!handler) throw new Error("Missing arg-menu action handler");
if (!handler) {
throw new Error("Missing arg-menu action handler");
}
await handler({
ack: vi.fn().mockResolvedValue(undefined),