only add if there are new files
This commit is contained in:
parent
c1d0e044c7
commit
b6412c116d
1 changed files with 3 additions and 2 deletions
|
@ -371,8 +371,9 @@ class Client(object):
|
|||
sql = u'SELECT oshash FROM encode WHERE site = ?'
|
||||
c.execute(sql, (site, ))
|
||||
known = [row[0] for row in c]
|
||||
files = list(set(files) - set(known))
|
||||
conn.close()
|
||||
files = list(set(files) - set(known))
|
||||
if files:
|
||||
self.add_encodes(site, files)
|
||||
else:
|
||||
self.set_encodes(site, files)
|
||||
|
|
Loading…
Reference in a new issue