Browse Source

fix normalizeEntity method on null value

Olivier Massot 1 year ago
parent
commit
a2b5eb041a
1 changed files with 1 additions and 1 deletions
  1. 1 1
      services/data/normalizer/hydraNormalizer.ts

+ 1 - 1
services/data/normalizer/hydraNormalizer.ts

@@ -27,7 +27,7 @@ class HydraNormalizer {
           return UrlUtils.makeIRI(targetEntity, id)
         })
       } else {
-        entity[field] = UrlUtils.makeIRI(targetEntity, value)
+        entity[field] = value !== null ? UrlUtils.makeIRI(targetEntity, value) : null
       }
     }