Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import { getContentType } from 'baileys'
- async function plugin({ sock, jid, text, m, q, prefix, command, other }) {
- // [!] WAJIB PAKAI BAILEYS WHISKEYSOCKET DI GITHIB YA! JANGAN YANG NPM KARENA BELUM UPDATE NORMALIZE MESSAGE FUNCTION,
- // kalian eksperimen ya, sengaja aku gak buatin filter quoted nya, kalian bikin sendiri sesuai selera
- // cara ini cuma work untuk quoted message
- // by wolep, soalnya ini jg bisa swgc extended text message yang isi thumbnail kaya ig, yt, dll...
- const ct = getContentType(m.message)
- const WAMC = {
- groupStatusMessageV2: {
- message: m.message[ct].contextInfo.quotedMessage
- }
- }
- let temp = WAMC
- // kalian pasti bingung kenapa musti nested objek pakai looping.
- // percayalah cara ini buat counter fungsi yang di update terbaru
- // jaga" swgc terbaru kalau swgc kalian suatu saat gak worek saat update baileys dirilis ke npm
- for (let i = 0; i < 5; i++) {
- const n = {
- groupStatusMessageV2 : {
- message: temp
- }
- }
- temp = n
- }
- return await sock.relayMessage(jid, temp, {})
- }
- plugin.title = 'upload gc story'
- plugin.command = ['swgc']
- plugin.category = ['wacap']
- plugin.description = 'upload story'
- export default plugin
Add Comment
Please, Sign In to add comment