|
|
|
|
@@ -16,10 +16,10 @@ feature.hears(/^\/help/, logHandle("help"), async (ctx: Context) => {
|
|
|
|
|
: undefined;
|
|
|
|
|
|
|
|
|
|
// Checks there is a chat and msg property in the context.
|
|
|
|
|
if (ctx.chat && ctx.msg) {
|
|
|
|
|
if (ctx.chat && ctx.msg && ctx.msg.from) {
|
|
|
|
|
// Checks if the chat is private
|
|
|
|
|
if (ctx.chat.type === "private") {
|
|
|
|
|
// Responds with the command list.
|
|
|
|
|
// Responds with message.
|
|
|
|
|
await ctx.reply(
|
|
|
|
|
`Currently I have no commands for the public beta\\. I require no configuration\\. Simply add me to a group and make me an admin with the permission to delete messages\\. From there I will start deleting any Twitter\\/X and Meta links I detect\\. I also check embeds and forwards\\. Use /\\botInfo to learn more about my mission and why I was created\\.`,
|
|
|
|
|
{
|
|
|
|
|
@@ -29,14 +29,27 @@ feature.hears(/^\/help/, logHandle("help"), async (ctx: Context) => {
|
|
|
|
|
);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// Checks if chat is a group.
|
|
|
|
|
if (ctx.chat.type !== "private") {
|
|
|
|
|
await ctx.reply(
|
|
|
|
|
`Currently I have no commands for the public beta\\. I require no configuration\\. If I am not working\\, make sure I have an admin role with the permission to delete messages\\. I should already be deleting any Twitter\\/X and Meta links I detect\\. I also check embeds and forwards\\. Use /\\botInfo to learn more about my mission and why I was created\\.`,
|
|
|
|
|
{
|
|
|
|
|
parse_mode: "MarkdownV2",
|
|
|
|
|
reply_parameters: { message_id: ctx.msg.message_id }
|
|
|
|
|
}
|
|
|
|
|
);
|
|
|
|
|
const chatMember = await ctx.getChatMember(ctx.msg.from.id);
|
|
|
|
|
|
|
|
|
|
// Checks if the user is an admin.
|
|
|
|
|
if (["creator", "administrator"].includes(chatMember.status)) {
|
|
|
|
|
// Respond with message.
|
|
|
|
|
await ctx.reply(
|
|
|
|
|
`Currently I have no commands for the public beta\\. I require no configuration\\. If I am not working\\, make sure I have an admin role with the permission to delete messages\\. I should already be deleting any Twitter\\/X and Meta links I detect\\. I also check embeds and forwards\\. Use /\\botInfo to learn more about my mission and why I was created\\.`,
|
|
|
|
|
{
|
|
|
|
|
parse_mode: "MarkdownV2",
|
|
|
|
|
reply_parameters: { message_id: ctx.msg.message_id }
|
|
|
|
|
}
|
|
|
|
|
);
|
|
|
|
|
} else {
|
|
|
|
|
/**
|
|
|
|
|
* Doesn't respond to regular users in groups. This is to prevent users spamming the command.
|
|
|
|
|
* Especially since this one includes some political opinions/messages.
|
|
|
|
|
*/
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
await ctx.reply(
|
|
|
|
|
@@ -48,7 +61,7 @@ feature.hears(/^\/help/, logHandle("help"), async (ctx: Context) => {
|
|
|
|
|
);
|
|
|
|
|
|
|
|
|
|
return await ctx.reply(
|
|
|
|
|
`Down with fascism\\! Fuck MAGA\\! Fuck Trump\\! Fuck Nazis\\! Trans rights are human rights\\! Trans women are women\\! Trans men and men\\! Never let them take awy your happiness\\!`,
|
|
|
|
|
`Down with fascism\\! Fuck MAGA\\! Fuck Trump\\! Fuck Nazis\\! Trans rights are human rights\\! Trans women are women\\! Trans men are men\\! Never let them take away your happiness\\!`,
|
|
|
|
|
{
|
|
|
|
|
parse_mode: "MarkdownV2",
|
|
|
|
|
reply_parameters: { message_id: ctx.msg.message_id }
|
|
|
|
|
|