[whatsapp] make DocumentMessage handler use FileName attribute.
referenced: https://github.com/Rhymen/go-whatsapp/blob/master/message.go#L582
This commit is contained in:
@@ -359,7 +359,7 @@ func (b *Bwhatsapp) HandleDocumentMessage(message whatsapp.DocumentMessage) {
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
filename := fmt.Sprintf("%v%v", message.Info.Id, fileExt[0])
|
filename := fmt.Sprintf("%v", message.FileName)
|
||||||
|
|
||||||
b.Log.Debugf("Trying to download %s with type %s", filename, message.Type)
|
b.Log.Debugf("Trying to download %s with type %s", filename, message.Type)
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user