Skip to content

Commit

Permalink
Fix missing media
Browse files Browse the repository at this point in the history
  • Loading branch information
Kry9toN committed Jan 22, 2021
1 parent 541c410 commit 6115e05
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions command/sticker.js
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,9 @@ module.exports = {
})
})
} else if ((client.isMedia || client.isQuotedImage) && colors.includes(args[0])) {
if (!client.isPmium && !client.isOwner) return client.reply(pesan.error.premium)
const encmedia = client.isQuotedImage ? JSON.parse(JSON.stringify(chat).replace('quotedM', 'm')).message.extendedTextMessage.contextInfo : chat
const media = await client.downloadAndSaveMediaMessage(encmedia)
await ffmpeg(`./${media}`)
.on('start', function (cmd) {
console.log('[SERVER] Started :', cmd)
Expand Down

0 comments on commit 6115e05

Please sign in to comment.