Remove unused vars

This commit is contained in:
flan 2017-11-03 01:40:39 +01:00
parent 8e13c92b6e
commit d2bbb7150c

View File

@ -96,7 +96,7 @@ class SyncCollectionHandler(anki.sync.Syncer):
} }
class SyncMediaHandler(anki.sync.MediaSyncer): class SyncMediaHandler(anki.sync.MediaSyncer):
operations = ['begin', 'mediaChanges', 'mediaSanity', 'mediaList', 'uploadChanges', 'downloadFiles'] operations = ['begin', 'mediaChanges', 'mediaSanity', 'uploadChanges', 'downloadFiles']
def __init__(self, col): def __init__(self, col):
anki.sync.MediaSyncer.__init__(self, col) anki.sync.MediaSyncer.__init__(self, col)
@ -110,7 +110,7 @@ class SyncMediaHandler(anki.sync.MediaSyncer):
'err':'' 'err':''
}) })
def uploadChanges(self, data, skey): def uploadChanges(self, data):
""" """
The zip file contains files the client hasn't synced with the server The zip file contains files the client hasn't synced with the server
yet ('dirty'), and info on files it has deleted from its own media dir. yet ('dirty'), and info on files it has deleted from its own media dir.
@ -265,7 +265,7 @@ class SyncMediaHandler(anki.sync.MediaSyncer):
return f.getvalue() return f.getvalue()
def mediaChanges(self, lastUsn, skey): def mediaChanges(self, lastUsn):
result = [] result = []
usn = self.col.media.lastUsn() usn = self.col.media.lastUsn()
fname = csum = None fname = csum = None
@ -601,7 +601,7 @@ class SyncApp(object):
if url not in self.valid_urls: if url not in self.valid_urls:
raise HTTPNotFound() raise HTTPNotFound()
if url == 'begin' or url == 'mediaChanges' or url == 'uploadChanges': if url == "begin":
data['skey'] = session.skey data['skey'] = session.skey
return self._execute_handler_method_in_thread(url, data, session) return self._execute_handler_method_in_thread(url, data, session)