fixed npe on rare occasion of show element in presence being null
This commit is contained in:
parent
2738d834b4
commit
6028bf4ee2
|
@ -44,7 +44,7 @@ public class Presences {
|
||||||
}
|
}
|
||||||
|
|
||||||
public static int parseShow(Element show) {
|
public static int parseShow(Element show) {
|
||||||
if (show == null) {
|
if ((show == null)||(show.getContent() == null)) {
|
||||||
return Presences.ONLINE;
|
return Presences.ONLINE;
|
||||||
} else if (show.getContent().equals("away")) {
|
} else if (show.getContent().equals("away")) {
|
||||||
return Presences.AWAY;
|
return Presences.AWAY;
|
||||||
|
|
Loading…
Reference in a new issue