This commit is contained in:
Kovid Goyal 2021-03-26 22:40:29 +05:30
parent ad3aab9bdd
commit 4eda7a69fd
No known key found for this signature in database
GPG Key ID: 06BC317B515ACE7C

View File

@ -1095,7 +1095,7 @@ class View:
if not self.book or not self.book.manifest:
return
index, refnum = reference.split('.')
index, refnum = int(index), int(refnum)
index, refnum = int(index), (int(refnum) if refnum else 1)
chapter_name = self.book.manifest.spine[index]
if not chapter_name:
return False