mirror of
https://github.com/JimmXinu/FanFicFare.git
synced 2026-05-08 04:23:01 +02:00
Improve handling for authors without authorUrl (mostly for teststory).
This commit is contained in:
parent
a4cc07c8ff
commit
df9065b1ba
2 changed files with 3 additions and 2 deletions
|
|
@ -1985,7 +1985,8 @@ class FanFicFarePlugin(InterfaceAction):
|
|||
|
||||
author_id_to_link_map = dict()
|
||||
for i, author in enumerate(authorlist):
|
||||
author_id_to_link_map[authorids[author]] = authurls[i]
|
||||
if len(authurls) > i:
|
||||
author_id_to_link_map[authorids[author]] = authurls[i]
|
||||
|
||||
# print("author_id_to_link_map:%s\n\n"%author_id_to_link_map)
|
||||
db.new_api.set_link_for_authors(author_id_to_link_map)
|
||||
|
|
|
|||
|
|
@ -683,7 +683,7 @@ class Story(Configurable):
|
|||
htmllist=[]
|
||||
for i, v in enumerate(self.getList('author')):
|
||||
if len(self.getList('authorUrl')) <= i:
|
||||
aurl = "no_author_link"
|
||||
aurl = None
|
||||
else:
|
||||
aurl = self.getList('authorUrl')[i]
|
||||
auth = v
|
||||
|
|
|
|||
Loading…
Reference in a new issue