mirror of
https://github.com/tulir/mautrix-whatsapp
synced 2024-12-13 09:03:10 +01:00
Try to ensure recovered panics still print stack traces
This commit is contained in:
parent
7413163df2
commit
db53b95ab1
3 changed files with 4 additions and 2 deletions
2
go.mod
2
go.mod
|
@ -12,7 +12,7 @@ require (
|
|||
maunium.net/go/mauflag v1.0.0
|
||||
maunium.net/go/maulogger/v2 v2.0.0
|
||||
maunium.net/go/mautrix v0.1.0-alpha.3.0.20190825132810-9d870654e9d2
|
||||
maunium.net/go/mautrix-appservice v0.1.0-alpha.3.0.20190825132837-ffcc1e3c7ed7
|
||||
maunium.net/go/mautrix-appservice v0.1.0-alpha.3.0.20190830063827-e7dcd7e42e7c
|
||||
)
|
||||
|
||||
replace (
|
||||
|
|
2
go.sum
2
go.sum
|
@ -62,3 +62,5 @@ maunium.net/go/mautrix-appservice v0.1.0-alpha.3.0.20190824195529-3507711d75aa h
|
|||
maunium.net/go/mautrix-appservice v0.1.0-alpha.3.0.20190824195529-3507711d75aa/go.mod h1:PZTnFsEUt4YALO/OGGyWXeQulBVGEPjI8FQ88XCbu/w=
|
||||
maunium.net/go/mautrix-appservice v0.1.0-alpha.3.0.20190825132837-ffcc1e3c7ed7 h1:0B3zGyfNVxdCcoFDgvDh8CW9U0gkCDvwKbP0a0UIUEQ=
|
||||
maunium.net/go/mautrix-appservice v0.1.0-alpha.3.0.20190825132837-ffcc1e3c7ed7/go.mod h1:FJRRpH5+p3wCfEt6u/3kMeu9aGX/pk2PqtvjRDRW74w=
|
||||
maunium.net/go/mautrix-appservice v0.1.0-alpha.3.0.20190830063827-e7dcd7e42e7c h1:jt0i4ZkHikhy0T5Lxe+ApvLChy1MdloxGjs/kaImHD4=
|
||||
maunium.net/go/mautrix-appservice v0.1.0-alpha.3.0.20190830063827-e7dcd7e42e7c/go.mod h1:FJRRpH5+p3wCfEt6u/3kMeu9aGX/pk2PqtvjRDRW74w=
|
||||
|
|
2
user.go
2
user.go
|
@ -460,7 +460,7 @@ func (user *User) updateLastConnectionIfNecessary() {
|
|||
|
||||
func (user *User) HandleError(err error) {
|
||||
if errors.Cause(err) != whatsapp.ErrInvalidWsData {
|
||||
user.log.Errorln("WhatsApp error:", err)
|
||||
user.log.Errorfln("WhatsApp error: %v", err)
|
||||
}
|
||||
if closed, ok := err.(*whatsapp.ErrConnectionClosed); ok {
|
||||
if closed.Code == 1000 && user.cleanDisconnection {
|
||||
|
|
Loading…
Reference in a new issue