This commit is contained in:
Alex Yatskov 2018-05-07 11:02:51 -07:00
parent 1e32f05bd5
commit 7a0b4e656d

View File

@ -462,16 +462,12 @@ class AnkiConnect:
@api() @api()
def sync(self): def sync(self):
print self.window().onSync() self.window().onSync()
@api() @api()
def multi(self, actions): def multi(self, actions):
response = [] return map(self.handler, actions)
for item in actions:
response.append(self.handler(item))
return response
# #
@ -487,7 +483,7 @@ class AnkiConnect:
def deckNamesAndIds(self): def deckNamesAndIds(self):
decks = {} decks = {}
for deck in self.deckNames(): for deck in self.deckNames():
decks[deck] = self.collection().decks.id(deck) decks[deck] = self.decks().id(deck)
return decks return decks