Skip to content

Commit feab485

Browse files
committed
fixed replace in BaseDocument
1 parent ffba5ff commit feab485

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/main/java/com/arangodb/entity/BaseDocument.java

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -182,7 +182,9 @@ public void addAttribute(String key, Object value) {
182182
* @param value the value of the attribute ti replace the old value
183183
*/
184184
public void updateAttribute (String key, Object value) {
185-
this.properties.replace(key, value);
185+
if (this.properties.containsKey(key)) {
186+
this.properties.put(key, value);
187+
}
186188
}
187189

188190
// /**

0 commit comments

Comments
 (0)