ibnusyawall / botane

2 stars 0 forks source link

help #1

Closed ZefianAlfian closed 3 years ago

ZefianAlfian commented 3 years ago

Error: Could not find MIME for Buffer ``const fs = require("fs") const fetch = require('node-fetch') const axios = require('axios') const { MessageType } = require("@adiwajshing/baileys") const { text, extendedText, contact, location, liveLocation, image, video, sticker, document, audio, product } = MessageType

exports.run = async (bot, message, args, from) => { const reply = (teks) => { bot.sendMessage(from, teks, text, {quoted: message}) } const getBuffer = async (url, options) => { try { options ? options : {} const res = await axios({ method: "get", url, headers: { 'DNT': 1, 'Upgrade-Insecure-Request': 1 }, ...options, responseType: 'arraybuffer' }) return res.data } catch (e) { console.log(Error : ${e}) } } if (args.length < 1) return reply('Where the text?') teks = body.slice(13) reply("Tunggu sebentar") anu = (https://docs-jojo.herokuapp.com/api/blackpink?text=${teks}) buff = await getBuffer(anu) bot.sendMessage(from, buff, image, {quoted: message, caption: "Berhasil"}) };

exports.help = { name: "txtblackpink", description: "Make logo blackpink", usage: "txtblackpink teks", cooldown: 5, };``

ibnusyawall commented 3 years ago

Why?