From 5616e679f513aaf4dc3f9e5688a23a2c47384d31 Mon Sep 17 00:00:00 2001 From: Damien Elmes Date: Mon, 10 May 2010 21:32:36 +0900 Subject: [PATCH] cache the css as a deck var, don't accidentally send it in sync --- anki/deck.py | 1 + anki/sync.py | 1 + 2 files changed, 2 insertions(+) diff --git a/anki/deck.py b/anki/deck.py index cc0835fd4..1046cf104 100644 --- a/anki/deck.py +++ b/anki/deck.py @@ -1315,6 +1315,7 @@ answerAlign, 0 from cardModels""")]) (hexifyID(row[0]), row[1]) for row in self.s.all(""" select id, lastFontColour from cardModels""")]) self.css = css + self.setVar("cssCache", css) return css def copyModel(self, oldModel): diff --git a/anki/sync.py b/anki/sync.py index 9a3d937cb..c1b7d2fed 100644 --- a/anki/sync.py +++ b/anki/sync.py @@ -606,6 +606,7 @@ values del d['path'] del d['syncName'] del d['version'] + del d['css'] # these may be deleted before bundling if 'models' in d: del d['models'] if 'currentModel' in d: del d['currentModel']