From 4d4595039245f49fa2461e60af59087ccc2a7653 Mon Sep 17 00:00:00 2001 From: Charles Haley <> Date: Fri, 17 Sep 2010 18:23:23 +0100 Subject: [PATCH] Fix problem with passing strings instead of lists for standard is_multiple fields --- src/calibre/gui2/dialogs/metadata_bulk.py | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/calibre/gui2/dialogs/metadata_bulk.py b/src/calibre/gui2/dialogs/metadata_bulk.py index 6bda4db138..173c69910f 100644 --- a/src/calibre/gui2/dialogs/metadata_bulk.py +++ b/src/calibre/gui2/dialogs/metadata_bulk.py @@ -317,7 +317,11 @@ class MetadataBulkDialog(QDialog, Ui_MetadataBulkDialog): v = apply_pattern(val).strip() if v: res.append(v) - val = fm['is_multiple'].join(res) + val = res + if fm['is_custom']: + # The standard tags and authors values want to be lists. + # All custom columns are to be strings + val = fm['is_multiple'].join(val) else: val = apply_pattern(val) @@ -330,8 +334,6 @@ class MetadataBulkDialog(QDialog, Ui_MetadataBulkDialog): setter = self.db.set_comment else: setter = getattr(self.db, 'set_'+field) - if field == 'authors': - val = string_to_authors(val) setter(id, val, notify=False, commit=False) self.db.commit()