From 7fc593a2ceb9abe3262e7deff0024f854c07045a Mon Sep 17 00:00:00 2001 From: Damien Elmes Date: Wed, 8 Dec 2010 17:05:19 +0900 Subject: [PATCH] fix tag update --- anki/importing/__init__.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/anki/importing/__init__.py b/anki/importing/__init__.py index ae55209e4..0742742ea 100644 --- a/anki/importing/__init__.py +++ b/anki/importing/__init__.py @@ -131,9 +131,9 @@ update fields set value = :v where factId = :fid and fieldModelId = :fmid""", data) # update tags self.deck.updateProgress() - if tagsIdx: - data = [{'factId': fid, - 'tags': c.fields[tagsIdx]} + if tagsIdx is not None: + data = [{'fid': fid, + 't': c.fields[tagsIdx]} for (fid, c) in upcards] self.deck.s.execute( "update facts set tags = :t where id = :fid",