Skip to content

Instantly share code, notes, and snippets.

@techgod143
Last active January 28, 2025 00:12
Show Gist options
  • Select an option

  • Save techgod143/78b4cfac574bb46f059db0093c56bfee to your computer and use it in GitHub Desktop.

Select an option

Save techgod143/78b4cfac574bb46f059db0093c56bfee to your computer and use it in GitHub Desktop.
antibc-Levanter
const { bot, setVar } = require('../lib')
bot(
{
pattern: 'antibc ?(.*)',
desc: 'set anti broadcast msg',
type: 'whatsapp',
},
async (message, match) => {
if (!match) await message.send('*Example :* setantibroadcastmsg dont send broadcast please!')
await setVar({ ANTI_BROADCAST_MSG: match }, message.id)
await message.send(`_new var ANTI_BROADCAST_MSG added as ${match}_`)
}
)
bot({ on: 'text', fromMe: false, type: 'antibroadcast' }, async (message, match, ctx) => {
if (message.jid.endsWith('@broadcast')) {
await message.send(
ctx.ANTI_BROADCAST_MSG || 'if you do not removeme from broadcast next time i will permanently ban or crash your number',
{
quoted: message.data,
},
'text',
message.message.key.participant
)
}
})
@balil9
Copy link

balil9 commented Jan 28, 2025

Anto recat

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment