forked from jshiffer/go-xmpp
Remove unreacheable panics
This commit is contained in:
2
xmpp.go
2
xmpp.go
@@ -554,7 +554,6 @@ func (c *Client) Recv() (stanza interface{}, err error) {
|
|||||||
return Presence{v.From, v.To, v.Type, v.Show}, nil
|
return Presence{v.From, v.To, v.Type, v.Show}, nil
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
panic("unreachable")
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// Send sends the message wrapped inside an XMPP message stanza body.
|
// Send sends the message wrapped inside an XMPP message stanza body.
|
||||||
@@ -726,7 +725,6 @@ func nextStart(p *xml.Decoder) (xml.StartElement, error) {
|
|||||||
return t, nil
|
return t, nil
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
panic("unreachable")
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// Scan XML token stream for next element and save into val.
|
// Scan XML token stream for next element and save into val.
|
||||||
|
Reference in New Issue
Block a user