Skip to content

Commit

Permalink
file() desperate, use toFileBox instead (#1481)
Browse files Browse the repository at this point in the history
  • Loading branch information
lijiarui authored and huan committed Jul 14, 2018
1 parent ac241d6 commit 8be801e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion examples/media-file-bot.ts
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ bot
console.log(`RECV: ${msg}`)

if (msg.type() !== Message.Type.Text) {
const file = await msg.file()
const file = await msg.toFileBox()
const name = file.name
console.log('Save file to: ' + name)
file.toFile(name)
Expand Down

0 comments on commit 8be801e

Please sign in to comment.