From a55e0dab1cabb7d7a41d99cc22ac2c3c317ca2ef Mon Sep 17 00:00:00 2001 From: Jacky Date: Fri, 15 Dec 2017 22:07:07 -0500 Subject: [PATCH] resolve the conflict --- main/src/com/google/refine/ProjectMetadata.java | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/main/src/com/google/refine/ProjectMetadata.java b/main/src/com/google/refine/ProjectMetadata.java index 5d7b14d3f..ba7997c54 100644 --- a/main/src/com/google/refine/ProjectMetadata.java +++ b/main/src/com/google/refine/ProjectMetadata.java @@ -36,6 +36,7 @@ package com.google.refine; import java.io.Serializable; import java.lang.reflect.Field; import java.time.LocalDateTime; +import java.util.ArrayList; import java.util.HashMap; import java.util.Iterator; import java.util.List; @@ -82,9 +83,6 @@ public class ProjectMetadata implements Jsonizable { private Map _customMetadata = new HashMap(); private PreferenceStore _preferenceStore = new PreferenceStore(); - private Map _customMetadata = new HashMap(); - private PreferenceStore _preferenceStore = new PreferenceStore(); - private final static Logger logger = LoggerFactory.getLogger("project_metadata"); protected ProjectMetadata(LocalDateTime date) { @@ -116,6 +114,8 @@ public class ProjectMetadata implements Jsonizable { writer.value(tag); } writer.endArray(); + writer.key("created"); writer.value(ParsingUtilities.localDateToString(_created)); + writer.key("modified"); writer.value(ParsingUtilities.localDateToString(_modified)); writer.key("creator"); writer.value(_creator); writer.key("contributors"); @@ -129,8 +129,7 @@ public class ProjectMetadata implements Jsonizable { writer.key("customMetadata"); writer.object(); - writer.key("created"); writer.value(ParsingUtilities.localDateToString(_created)); - writer.key("modified"); writer.value(ParsingUtilities.localDateToString(_modified)); + for (String key : _customMetadata.keySet()) { Serializable value = _customMetadata.get(key); writer.key(key);