Skip to content

Commit cc00b06

Browse files
committed
remove unused arguments
1 parent e626d6d commit cc00b06

File tree

4 files changed

+6
-6
lines changed

4 files changed

+6
-6
lines changed

packages/main/src/commands/ban.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import TelegramBot from '../telegram_bot';
22
import { TelegramUpdate } from '../types';
33

4-
export default async (self: TelegramBot, update: TelegramUpdate, args: string[]): Promise<Response> => {
4+
export default async (self: TelegramBot, update: TelegramUpdate): Promise<Response> => {
55
const chat_id = update.message?.reply_to_message?.chat.id;
66
const user_id = update.message?.reply_to_message?.from.id;
77
if (chat_id && user_id) {

packages/main/src/commands/mute.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import TelegramBot from '../telegram_bot';
22
import { TelegramUpdate } from '../types';
33

4-
export default async (self: TelegramBot, update: TelegramUpdate, args: string[]): Promise<Response> => {
4+
export default async (self: TelegramBot, update: TelegramUpdate): Promise<Response> => {
55
const chat_id = update.message?.reply_to_message?.chat.id;
66
const user_id = update.message?.reply_to_message?.from.id;
77
if (chat_id && user_id) {

packages/main/src/telegram_bot.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -41,8 +41,8 @@ export default class TelegramBot extends TelegramApi {
4141
ping: (self: TelegramBot, update: TelegramUpdate, args: string[]) => Promise<Response>;
4242
getChatInfo: (self: TelegramBot, update: TelegramUpdate) => Promise<Response>;
4343
start: (self: TelegramBot, update: TelegramUpdate) => Promise<Response>;
44-
ban: (self: TelegramBot, update: TelegramUpdate, args: string[]) => Promise<Response>;
45-
mute: (self: TelegramBot, update: TelegramUpdate, args: string[]) => Promise<Response>;
44+
ban: (self: TelegramBot, update: TelegramUpdate) => Promise<Response>;
45+
mute: (self: TelegramBot, update: TelegramUpdate) => Promise<Response>;
4646
url: URL;
4747
kv: Kv;
4848
get_set: KVNamespace;

packages/main/src/telegram_commands.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,6 @@ export default class TelegramCommands {
1818
static image: TelegramCommand = async (bot, update, args) => bot.image(bot, update, args);
1919
static translate: TelegramCommand = async (bot, update, args) => bot.translate(bot, update, args);
2020
static start: TelegramCommand = async (bot, update) => bot.start(bot, update);
21-
static ban: TelegramCommand = async (bot, update, args) => bot.ban(bot, update, args);
22-
static mute: TelegramCommand = async (bot, update, args) => bot.mute(bot, update, args);
21+
static ban: TelegramCommand = async (bot, update) => bot.ban(bot, update);
22+
static mute: TelegramCommand = async (bot, update) => bot.mute(bot, update);
2323
}

0 commit comments

Comments
 (0)