extract cover while importing
This commit is contained in:
parent
9aef3616ba
commit
2b46ad2c16
2 changed files with 4 additions and 3 deletions
|
@ -290,9 +290,8 @@ class Item(db.Model):
|
|||
self.update()
|
||||
self.update_cover()
|
||||
self.modified = datetime.now()
|
||||
db.session.add(self)
|
||||
db.session.commit()
|
||||
user = User.get_or_create(settings.USER_ID)
|
||||
self.save()
|
||||
user = state.user()
|
||||
if user in self.users:
|
||||
Changelog.record(user, 'edititem', self.id, record)
|
||||
|
||||
|
|
|
@ -60,6 +60,8 @@ def add_file(id, f, prefix):
|
|||
})
|
||||
item.added = datetime.now()
|
||||
item.scrape()
|
||||
item.update_cover()
|
||||
item.save()
|
||||
return file
|
||||
|
||||
def run_scan():
|
||||
|
|
Loading…
Reference in a new issue