Ignore invalid data received errors

This commit is contained in:
Tulir Asokan 2019-05-27 14:15:45 +03:00
parent 3f13e13d36
commit 498c0e4130

View file

@ -25,6 +25,7 @@ import (
"sync"
"time"
"github.com/pkg/errors"
"github.com/skip2/go-qrcode"
log "maunium.net/go/maulogger/v2"
@ -344,7 +345,7 @@ func (user *User) updateLastConnectionIfNecessary() {
}
func (user *User) HandleError(err error) {
if err != whatsapp.ErrInvalidWsData {
if errors.Cause(err) != whatsapp.ErrInvalidWsData {
user.log.Errorln("WhatsApp error:", err)
}
var msg string