Optimize code

This commit is contained in:
croneter 2018-12-21 15:18:19 +01:00
parent 5d6b8f1273
commit bd1b0cc533

View file

@ -602,9 +602,6 @@ class DownloadGen(object):
def __iter__(self):
return self
def next(self):
return self.__next__()
def __next__(self):
while True:
if len(self.xml):
@ -622,6 +619,8 @@ class DownloadGen(object):
raise StopIteration
LOG.debug('Waiting for download to finish')
next = __next__
def get(self, key, default=None):
return self.attrib.get(key, default)