X-Git-Url: https://git.mdrn.pl/wolnelektury.git/blobdiff_plain/4b6fc6dc545a10955094bfaa9448ba070cfb33bf..938fc832934e508085dad3645c01060a4dc9f0c9:/apps/catalogue/management/commands/importbooks.py diff --git a/apps/catalogue/management/commands/importbooks.py b/apps/catalogue/management/commands/importbooks.py index d097ddd1a..995132a82 100644 --- a/apps/catalogue/management/commands/importbooks.py +++ b/apps/catalogue/management/commands/importbooks.py @@ -46,11 +46,10 @@ class Command(BaseCommand): build_txt=options.get('build_txt'), build_pdf=options.get('build_pdf'), build_mobi=options.get('build_mobi')) - fileid = book.fileid() for ebook_format in Book.ebook_formats: if os.path.isfile(file_base + '.' + ebook_format): getattr(book, '%s_file' % ebook_format).save( - '%s.%s' % (fileid, ebook_format), + '%s.%s' % (book.slug, ebook_format), File(file(file_base + '.' + ebook_format))) if verbose: print "Importing %s.%s" % (file_base, ebook_format)