Skip to content
This repository has been archived by the owner on Dec 7, 2020. It is now read-only.

Commit

Permalink
serializers: type check fix
Browse files Browse the repository at this point in the history
* Fixes issue related to GetRecord in OAIServer.

Signed-off-by: Lars Holm Nielsen <lars.holm.nielsen@cern.ch>
  • Loading branch information
lnielsen committed Mar 29, 2016
1 parent 5c1c99e commit 2b4dc2d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion invenio_marc21/serializers/marcxml.py
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ def serialize_search(self, pid_fetcher, search_result,
def serialize_oaipmh(self, pid, record):
"""Serialize a single record for OAI-PMH."""
obj = self.transform_record(pid, record) \
if isinstance(record, Record) \
if isinstance(record['_source'], Record) \
else self.transform_search_hit(pid, record)

return dumps_etree(obj, **self.dumps_kwargs)

0 comments on commit 2b4dc2d

Please sign in to comment.