aboutsummaryrefslogtreecommitdiffstats
path: root/src/main/java/eu/siacs/conversations/entities
diff options
context:
space:
mode:
authoriNPUTmice <daniel@gultsch.de>2014-12-15 17:29:17 +0100
committeriNPUTmice <daniel@gultsch.de>2014-12-15 17:29:17 +0100
commite084266595855033d04950bf2fc1ea4ab244f1fe (patch)
tree438f7401b1e6343d47f83c84b9633eb60ef6b097 /src/main/java/eu/siacs/conversations/entities
parent25d8546ae89da97e975e72e9eb2f0608fb38aad5 (diff)
migrated more jid parsing to use getAttributeAsJid. added error logging
Diffstat (limited to 'src/main/java/eu/siacs/conversations/entities')
-rw-r--r--src/main/java/eu/siacs/conversations/entities/Bookmark.java11
1 files changed, 1 insertions, 10 deletions
diff --git a/src/main/java/eu/siacs/conversations/entities/Bookmark.java b/src/main/java/eu/siacs/conversations/entities/Bookmark.java
index 70d852fe..20905648 100644
--- a/src/main/java/eu/siacs/conversations/entities/Bookmark.java
+++ b/src/main/java/eu/siacs/conversations/entities/Bookmark.java
@@ -60,16 +60,7 @@ public class Bookmark extends Element implements ListItem {
@Override
public Jid getJid() {
- final String jid = this.getAttribute("jid");
- if (jid != null) {
- try {
- return Jid.fromString(jid);
- } catch (final InvalidJidException e) {
- return null;
- }
- } else {
- return null;
- }
+ return this.getAttributeAsJid("jid");
}
@Override