mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-14 06:25:10 +00:00
Fix lint in telegram poll action handler
This commit is contained in:
parent
c43e95e011
commit
b2fe44b1ee
1 changed files with 2 additions and 2 deletions
|
|
@ -220,7 +220,7 @@ export async function handleTelegramAction(
|
|||
}
|
||||
const to = readStringParam(params, "to", { required: true });
|
||||
const question = readStringParam(params, "question", { required: true });
|
||||
const options = (params.options ?? params.answers) as unknown;
|
||||
const options = params.options ?? params.answers;
|
||||
if (!Array.isArray(options)) {
|
||||
throw new Error("options must be an array of strings");
|
||||
}
|
||||
|
|
@ -241,7 +241,7 @@ export async function handleTelegramAction(
|
|||
integer: true,
|
||||
});
|
||||
const maxSelections =
|
||||
typeof params.allowMultiselect === "boolean" && params.allowMultiselect === true ? 2 : 1;
|
||||
typeof params.allowMultiselect === "boolean" && params.allowMultiselect ? 2 : 1;
|
||||
const token = resolveTelegramToken(cfg, { accountId }).token;
|
||||
if (!token) {
|
||||
throw new Error(
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue