Use fedireads key as default author identifier

This commit is contained in:
Mouse Reeve 2020-03-28 16:38:20 -07:00
parent 06ff795df1
commit 77e6e2d708
2 changed files with 2 additions and 2 deletions

View file

@ -56,7 +56,7 @@ urlpatterns = [
re_path(r'^book/(?P<book_identifier>[\w\-]+)/(?P<tab>friends|local|federated)?$', views.book_page),
re_path(r'^book/(?P<book_identifier>[\w\-]+)/edit/?$', views.edit_book_page),
re_path(r'^author/(?P<author_identifier>\w+)/?$', views.author_page),
re_path(r'^author/(?P<author_identifier>[\w\-]+)/?$', views.author_page),
re_path(r'^tag/(?P<tag_id>.+)/?$', views.tag_page),
re_path(r'^shelf/%s/(?P<shelf_identifier>[\w-]+)(.json)?/?$' % username_regex, views.shelf_page),
re_path(r'^shelf/%s/(?P<shelf_identifier>[\w-]+)(.json)?/?$' % localname_regex, views.shelf_page),

View file

@ -409,7 +409,7 @@ def edit_book_page(request, book_identifier):
def author_page(request, author_identifier):
''' landing page for an author '''
try:
author = models.Author.objects.get(openlibrary_key=author_identifier)
author = models.Author.objects.get(fedireads_key=author_identifier)
except ValueError:
return HttpResponseNotFound()