Revert "moveTemplate slightly quicker"

This reverts commit b29fd508c7.

This caused a regression:
https://github.com/dae/anki/pull/294
This commit is contained in:
Damien Elmes 2019-03-11 13:49:58 +10:00
parent 44952ff727
commit 3cf770c73c

View file

@ -396,10 +396,7 @@ update cards set ord = ord - 1, usn = ?, mod = ?
# generate change map
map = []
for t in m['tmpls']:
oldidx = oldidxs[id(t)]
newidx = t['ord']
if oldidx != newidx:
map.append("when ord = %d then %d" % (oldidx, newidx))
map.append("when ord = %d then %d" % (oldidxs[id(t)], t['ord']))
# apply
self.save(m)
self.col.db.execute("""