make mobi wasn't setting provider
parent
3ae537132e
commit
15d281c988
|
@ -23,11 +23,14 @@ class Command(BaseCommand):
|
||||||
ebf = ebook.get_archive_ebf()
|
ebf = ebook.get_archive_ebf()
|
||||||
if ebf:
|
if ebf:
|
||||||
try:
|
try:
|
||||||
|
print 'making mobi for {}'.format(work.title)
|
||||||
if ebf.make_mobi():
|
if ebf.make_mobi():
|
||||||
print 'made mobi for {}'.format(ebf.edition.work.title)
|
print 'made mobi'
|
||||||
i = i + 1
|
i = i + 1
|
||||||
break
|
break
|
||||||
|
else:
|
||||||
|
print 'failed to make mobi'
|
||||||
except:
|
except:
|
||||||
pass
|
print 'failed to make mobi'
|
||||||
if i >= max:
|
if i >= max:
|
||||||
break
|
break
|
||||||
|
|
|
@ -1089,6 +1089,7 @@ class EbookFile(models.Model):
|
||||||
new_ebook = Ebook.objects.create(
|
new_ebook = Ebook.objects.create(
|
||||||
edition=self.edition,
|
edition=self.edition,
|
||||||
format='mobi',
|
format='mobi',
|
||||||
|
provider='Unglue.it',
|
||||||
url=new_mobi_ebf.file.url,
|
url=new_mobi_ebf.file.url,
|
||||||
rights=self.ebook.rights,
|
rights=self.ebook.rights,
|
||||||
version_label=self.ebook.version_label,
|
version_label=self.ebook.version_label,
|
||||||
|
|
Loading…
Reference in New Issue