diff --git a/src/main/java/w2phtml/rdf/DocumentPart.java b/src/main/java/w2phtml/rdf/DocumentPart.java
index 46ec8dd..d05e839 100644
--- a/src/main/java/w2phtml/rdf/DocumentPart.java
+++ b/src/main/java/w2phtml/rdf/DocumentPart.java
@@ -65,13 +65,12 @@ public class DocumentPart {
if (metaElements.hasAttribute("name") && metaElements.hasAttribute("content")) {
String metaName = metaElements.getAttribute("name");
String metaValue = metaElements.getAttribute("content");
- if (metadata.containsKey(metaName)) {
- metadata.get(metaName).add(metaValue);
- } else {
+ if (!metadata.containsKey(metaName)) {
Set names = new HashSet();
- names.add(metaValue);
metadata.put(metaName, names);
}
+ Set names = metadata.get(metaName);
+ names.add(metaValue);
}
}
}