only pass non default timeout

This commit is contained in:
j 2014-10-04 13:27:02 +02:00
parent fbb702e349
commit c133e853f8

View file

@ -104,8 +104,11 @@ class Imdb(models.Model):
data['title'] = data['title'].strip()
return data
def update(self):
info = ox.web.imdb.ImdbCombined(self.imdb)
def update(self, timeout=None):
if timeout != None:
info = ox.web.imdb.ImdbCombined(self.imdb, timeout=timeout)
else:
info = ox.web.imdb.ImdbCombined(self.imdb)
info = self.apply_patch(info)
if info:
for key in self.keys: