diff options
author | Daniel Gultsch <daniel@gultsch.de> | 2015-05-14 14:42:21 +0200 |
---|---|---|
committer | Daniel Gultsch <daniel@gultsch.de> | 2015-05-20 03:48:14 +0200 |
commit | e32f380dae4913d8152fc92b76193de241089cf8 (patch) | |
tree | 788ee2f2a2c5f3eeff479d66b817f2ab059ca629 /src/main/java/eu/siacs/conversations/parser | |
parent | 7824c01748a89688c5f76307cc1f4221a9e2ffb5 (diff) |
provide helper function for getting the content of a child directly
Diffstat (limited to '')
-rw-r--r-- | src/main/java/eu/siacs/conversations/parser/AbstractParser.java | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/src/main/java/eu/siacs/conversations/parser/AbstractParser.java b/src/main/java/eu/siacs/conversations/parser/AbstractParser.java index bfe84440e..6f73f24da 100644 --- a/src/main/java/eu/siacs/conversations/parser/AbstractParser.java +++ b/src/main/java/eu/siacs/conversations/parser/AbstractParser.java @@ -70,10 +70,6 @@ public abstract class AbstractParser { if (item == null) { return null; } - Element data = item.findChild("data", "urn:xmpp:avatar:data"); - if (data == null) { - return null; - } - return data.getContent(); + return item.findChildContent("data", "urn:xmpp:avatar:data"); } } |