Detect errors when working with AvatarData
This commit is contained in:
@@ -283,7 +283,13 @@ func (b *Bxmpp) handleXMPP() error {
|
|||||||
for {
|
for {
|
||||||
m, err := b.xc.Recv()
|
m, err := b.xc.Recv()
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
switch m.(type) {
|
||||||
|
case xmpp.AvatarData:
|
||||||
|
b.avatarAvailability[v.From] = false
|
||||||
|
continue
|
||||||
|
default:
|
||||||
|
return err
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
switch v := m.(type) {
|
switch v := m.(type) {
|
||||||
|
|||||||
Reference in New Issue
Block a user