const fs = require("fs-extra"); const request = require("request"); const path = require("path"); module.exports = { config: { name: "owner", version: "1.3.0", author: "ᴇꜰx ᴀꜱɪꜰ", role: 0, shortDescription: "Owner information with image", category: "Information", guide: { en: "owner" } }, onStart: async function ({ api, event }) { const ownerText = `╭─ 👑 Oᴡɴᴇʀ Iɴғᴏ 👑 ─╮ │ 👤 Nᴀᴍᴇ : ᴇꜰx ᴀꜱɪꜰ │ 🧸 Nɪᴄᴋ : ᴇᴠᴏ │ 🎂 Aɢᴇ : 16+ │ 💘 Rᴇʟᴀᴛɪᴏɴ : Sɪɴɢʟᴇ │ 🎓 Pʀᴏғᴇssɪᴏɴ : Sᴛᴜᴅᴇɴᴛ │ 📚 Eᴅᴜᴄᴀᴛɪᴏɴ : ᴇᴏʀʀᴏ │ 🏡 Lᴏᴄᴀᴛɪᴏɴ : 𝐉𝐨𝐬𝐬𝐨𝐫 ├─ 🔗 Cᴏɴᴛᴀᴄᴛ ─╮ │ 📘 Facebook : fb.com/asi.f.007xll │ 💬 Messenger: m.me/asi.f.007xll │ 📞 WhatsApp : wa.me/01930237805 ╰────────────────╯`; const cacheDir = path.join(__dirname, "cache"); const imgPath = path.join(cacheDir, "owner.jpg"); if (!fs.existsSync(cacheDir)) fs.mkdirSync(cacheDir); const imgLink = "https://i.postimg.cc/KvbMMm4T/ezgif-814221cf15923f06.gif"; const send = () => { api.sendMessage( { body: ownerText, attachment: fs.createReadStream(imgPath) }, event.threadID, () => fs.unlinkSync(imgPath), event.messageID ); }; request(encodeURI(imgLink)) .pipe(fs.createWriteStream(imgPath)) .on("close", send); } };