Commit 0beede17 authored by Jonas Waeber's avatar Jonas Waeber
Browse files

Always insert a placeholder institution.

parent 2cbd1199
......@@ -30,7 +30,12 @@ object InstitutionAndRecordSetExtractionHelper {
private val log = LogManager.getLogger("InstitutionAndRecordSetExtractionHelper")
fun extractInstitution(record: JsonObject): List<FacetContainer> {
return extract(KEYS.heldBy, record)
val containers = extract(KEYS.heldBy, record)
return if (containers.isNotEmpty()) {
containers
} else {
listOf(FacetContainer.placeholder("NoInstitutionInRecord"))
}
}
fun extractRecordSet(record: JsonObject): FacetContainer {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment