From 2792ea25e2ebe5d4c5e943b563a5918f16977135 Mon Sep 17 00:00:00 2001 From: Dmitry Shelepnev <mitshel@mail.ru> Date: Mon, 27 Feb 2017 23:25:25 +0300 Subject: [PATCH] Fix error on author last_name move to top --- opds_catalog/sopdscan.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/opds_catalog/sopdscan.py b/opds_catalog/sopdscan.py index ffcc248..f546eab 100644 --- a/opds_catalog/sopdscan.py +++ b/opds_catalog/sopdscan.py @@ -229,7 +229,7 @@ class opdsScanner: for a in book_data.authors: author_name = a.get('name','Unknown author').strip(strip_symbols) # Если в имени автора нет запятой, то фамилию переносим из конца в начало - if author_name.find(',')<0: + if author_name.find(',')>=0: author_names = author_name.split() author_name = ' '.join([author_names[-1],' '.join(author_names[:-1])]) author=opdsdb.addauthor(author_name) -- GitLab