-# -*- coding: utf-8 -*-
-# This file is part of Wolnelektury, licensed under GNU Affero GPLv3 or later.
-# Copyright © Fundacja Nowoczesna Polska. See NOTICE for more information.
+# This file is part of Wolne Lektury, licensed under GNU Affero GPLv3 or later.
+# Copyright © Fundacja Wolne Lektury. See NOTICE for more information.
texml = BytesIO(rendered.encode('utf-8'))
tempdir = mkdtemp(prefix="render_to_pdf-")
tex_path = os.path.join(tempdir, "doc.tex")
texml = BytesIO(rendered.encode('utf-8'))
tempdir = mkdtemp(prefix="render_to_pdf-")
tex_path = os.path.join(tempdir, "doc.tex")
makedirs(os.path.dirname(output_path))
rendered = render_to_string(template, context)
makedirs(os.path.dirname(output_path))
rendered = render_to_string(template, context)
response = HttpResponse(content_type=mime_type)
response['Content-Disposition'] = 'attachment; filename=%s' % name
response = HttpResponse(content_type=mime_type)
response['Content-Disposition'] = 'attachment; filename=%s' % name