diff --git a/common/doi/mapping.py b/common/doi/mapping.py index 3e03262c..ae1db21b 100644 --- a/common/doi/mapping.py +++ b/common/doi/mapping.py @@ -23,6 +23,8 @@ def metadata_check(self, data): errors[ f"metadata.creators[{i}].authorityIdentifiers[{j}].scheme" ] = [missing_data_message] + if "publishers" not in data: + errors["metadata.publishers"] = [missing_data_message] if "contributors" in data: for i, contributor in enumerate(data["contributors"]): if "fullName" not in contributor: @@ -63,10 +65,7 @@ def create_datacite_payload(self, data): metadata = data["metadata"] creators = creatibutor(metadata, "creators") titles = title(metadata) - # publishers = publisher(data) - - # todo: what is the correct value here? if it should be from the record data - check also needs to be added since publisher field is mandatory in DC - publishers = "NTK" + publishers = publisher(metadata) dc_resource_type = resource_type(metadata)