Skip to content

Commit

Permalink
Added leader[9] test for utf-8 output in record.as_marc()
Browse files Browse the repository at this point in the history
  • Loading branch information
mbklein committed Sep 2, 2010
1 parent 1ffdcbb commit ff31286
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pymarc/record.py
Expand Up @@ -217,7 +217,7 @@ def as_marc(self):
# can be found
for field in self.fields:
field_data = field.as_marc()
if self.force_utf8:
if self.leader[9] == 'a' or self.force_utf8:
field_data = field_data.encode('utf-8')
fields += field_data
if field.tag.isdigit():
Expand Down

0 comments on commit ff31286

Please sign in to comment.