diff --git a/CHANGELOG.md b/CHANGELOG.md index a582f53bf..dfefa8360 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,6 +6,10 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/) ## Unreleased +### Fixed + +- Fixed Nullpointer in `Manifestation.dumpShortenedRelations` + ## [9.2.1](https://github.com/dbmdz/metadata-service/releases/tag/9.2.1) - 2024-06-11 ### Fixed diff --git a/metasvc-model/src/main/java/de/digitalcollections/model/identifiable/entity/manifestation/Manifestation.java b/metasvc-model/src/main/java/de/digitalcollections/model/identifiable/entity/manifestation/Manifestation.java index 4a4870890..31f46f5ba 100644 --- a/metasvc-model/src/main/java/de/digitalcollections/model/identifiable/entity/manifestation/Manifestation.java +++ b/metasvc-model/src/main/java/de/digitalcollections/model/identifiable/entity/manifestation/Manifestation.java @@ -411,7 +411,11 @@ public int hashCode() { */ private String dumpShortenedRelations(List relations) { return "[" - + relations.stream().map(EntityRelation::toShortenedString).collect(Collectors.joining(",")) + + (relations == null + ? "null" + : relations.stream() + .map(EntityRelation::toShortenedString) + .collect(Collectors.joining(","))) + "]"; }