mirror of
https://github.com/tulir/mautrix-whatsapp
synced 2024-12-15 09:53:47 +01:00
Ignore file length mismatches again
This commit is contained in:
parent
86486419dc
commit
a6adf61417
1 changed files with 2 additions and 0 deletions
|
@ -1692,6 +1692,8 @@ func (portal *Portal) convertMediaMessage(intent *appservice.IntentAPI, source *
|
||||||
if errors.Is(err, whatsmeow.ErrNoURLPresent) {
|
if errors.Is(err, whatsmeow.ErrNoURLPresent) {
|
||||||
portal.log.Debugfln("No URL present error for media message %s, ignoring...", info.ID)
|
portal.log.Debugfln("No URL present error for media message %s, ignoring...", info.ID)
|
||||||
return nil
|
return nil
|
||||||
|
} else if errors.Is(err, whatsmeow.ErrFileLengthMismatch) || errors.Is(err, whatsmeow.ErrInvalidMediaSHA256) {
|
||||||
|
portal.log.Warnfln("Mismatching media checksums in %s: %v. Ignoring because WhatsApp seems to ignore them too", info.ID, err)
|
||||||
} else if err != nil {
|
} else if err != nil {
|
||||||
return portal.makeMediaBridgeFailureMessage(intent, info, err, captionContent)
|
return portal.makeMediaBridgeFailureMessage(intent, info, err, captionContent)
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue