mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-06 22:51:36 +00:00
chore: Enable typescript/no-explicit-any rule.
This commit is contained in:
@@ -86,6 +86,7 @@ export async function handleCommands(params: HandleCommandsParams): Promise<Comm
|
||||
// Send hook messages immediately if present
|
||||
if (hookEvent.messages.length > 0) {
|
||||
// Use OriginatingChannel/To if available, otherwise fall back to command channel/from
|
||||
// oxlint-disable-next-line typescript/no-explicit-any
|
||||
const channel = params.ctx.OriginatingChannel || (params.command.channel as any);
|
||||
// For replies, use 'from' (the sender) not 'to' (which might be the bot itself)
|
||||
const to = params.ctx.OriginatingTo || params.command.from || params.command.to;
|
||||
|
||||
@@ -25,6 +25,7 @@ export type InlineActionResult =
|
||||
abortedLastRun: boolean;
|
||||
};
|
||||
|
||||
// oxlint-disable-next-line typescript/no-explicit-any
|
||||
function extractTextFromToolResult(result: any): string | null {
|
||||
if (!result || typeof result !== "object") {
|
||||
return null;
|
||||
@@ -193,6 +194,7 @@ export async function handleInlineActions(params: {
|
||||
command: rawArgs,
|
||||
commandName: skillInvocation.command.name,
|
||||
skillName: skillInvocation.command.skillName,
|
||||
// oxlint-disable-next-line typescript/no-explicit-any
|
||||
} as any);
|
||||
const text = extractTextFromToolResult(result) ?? "✅ Done.";
|
||||
typing.cleanup();
|
||||
|
||||
@@ -285,6 +285,7 @@ export async function runPreparedReply(
|
||||
}
|
||||
}
|
||||
if (resetTriggered && command.isAuthorizedSender) {
|
||||
// oxlint-disable-next-line typescript/no-explicit-any
|
||||
const channel = ctx.OriginatingChannel || (command.channel as any);
|
||||
const to = ctx.OriginatingTo || command.from || command.to;
|
||||
if (channel && to) {
|
||||
|
||||
Reference in New Issue
Block a user