mirror of
https://github.com/janeczku/calibre-web
synced 2024-11-24 10:37:23 +00:00
Bugfix parsing /Keywords' in doc_info of pdf file with type bytes (fixes #2302)
This commit is contained in:
parent
95e0255aa1
commit
e0bf829def
@ -233,6 +233,9 @@ def pdf_meta(tmp_file_path, original_file_name, original_file_extension):
|
|||||||
if subject == '':
|
if subject == '':
|
||||||
subject = doc_info.subject
|
subject = doc_info.subject
|
||||||
if tags == '' and '/Keywords' in doc_info:
|
if tags == '' and '/Keywords' in doc_info:
|
||||||
|
if isinstance(doc_info['/Keywords'], bytes):
|
||||||
|
tags = doc_info['/Keywords'].decode('utf-8')
|
||||||
|
else:
|
||||||
tags = doc_info['/Keywords']
|
tags = doc_info['/Keywords']
|
||||||
else:
|
else:
|
||||||
title = original_file_name
|
title = original_file_name
|
||||||
|
@ -33,7 +33,7 @@ rarfile>=2.7
|
|||||||
scholarly>=1.2.0,<1.6
|
scholarly>=1.2.0,<1.6
|
||||||
|
|
||||||
# Comics
|
# Comics
|
||||||
natsort>=2.2.0,<8.1.0
|
natsort>=2.2.0,<8.2.0
|
||||||
comicapi>=2.2.0,<2.3.0
|
comicapi>=2.2.0,<2.3.0
|
||||||
|
|
||||||
# Kobo integration
|
# Kobo integration
|
||||||
|
Loading…
Reference in New Issue
Block a user