From 9955048aecf32ddd1826b5c167cd39efa0977a0c Mon Sep 17 00:00:00 2001 From: Arthur Milchior Date: Wed, 13 Nov 2019 17:02:12 +0100 Subject: [PATCH] DeckManager: _checkDeckTree ignore case --- anki/decks.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/anki/decks.py b/anki/decks.py index 8d8a73108..d07cbd2c9 100644 --- a/anki/decks.py +++ b/anki/decks.py @@ -454,7 +454,7 @@ class DeckManager: for deck in decks: # two decks with the same name? - if deck['name'] in names: + if self.normalizeName(deck['name']) in names: self.col.log("fix duplicate deck name", deck['name']) deck['name'] += "%d" % intTime(1000) self.save(deck) @@ -468,12 +468,12 @@ class DeckManager: # immediate parent must exist if "::" in deck['name']: immediateParent = "::".join(deck['name'].split("::")[:-1]) - if immediateParent not in names: + if self.normalizeName(immediateParent) not in names: self.col.log("fix deck with missing parent", deck['name']) self._ensureParents(deck['name']) - names.add(immediateParent) + names.add(self.normalizeName(immediateParent)) - names.add(deck['name']) + names.add(self.normalizeName(deck['name'])) def checkIntegrity(self): self._recoverOrphans()