[Bug]: authors with two surnames are sorted improperly #2057

Closed
opened 2026-04-25 00:03:02 +02:00 by adam · 1 comment
Owner

Originally created by @random-human-being on GitHub (Jun 14, 2024).

What happened?

Currently, when sorting authors, the last word in the "authors" field is assumed to be the surname.

This is not always the case, especially in countries where people take both parents' surnames. For example, the author "Gabriel García Márquez" is currently erroneously sorted as "Márquez, Gabriel García". In fact, it should be sorted as "García Márquez, Gabriel".

What did you expect to happen?

OPF files generated via Calibre already include an "author_sort" field, which could be scraped as-is. Not sure about other providers.

Steps to reproduce the issue

Add any book written by an author with two surnames; sort books by "Author Last, First"

Audiobookshelf version

v2.10.1

How are you running audiobookshelf?

Docker

What OS is your Audiobookshelf server hosted from?

Linux

If the issue is being seen in the UI, what browsers are you seeing the problem on?

Firefox

Logs

No response

Additional Notes

No response

Originally created by @random-human-being on GitHub (Jun 14, 2024). ### What happened? Currently, when sorting authors, the last word in the "authors" field is assumed to be the surname. This is not always the case, especially in countries where people take both parents' surnames. For example, the author "Gabriel García Márquez" is currently erroneously sorted as "Márquez, Gabriel García". In fact, it should be sorted as "García Márquez, Gabriel". ### What did you expect to happen? OPF files generated via Calibre already include an "author_sort" field, which could be scraped as-is. Not sure about other providers. ### Steps to reproduce the issue Add any book written by an author with two surnames; sort books by "Author Last, First" ### Audiobookshelf version v2.10.1 ### How are you running audiobookshelf? Docker ### What OS is your Audiobookshelf server hosted from? Linux ### If the issue is being seen in the UI, what browsers are you seeing the problem on? Firefox ### Logs _No response_ ### Additional Notes _No response_
adam added the bug label 2026-04-25 00:03:02 +02:00
adam closed this issue 2026-04-25 00:03:02 +02:00
Author
Owner

@advplyr commented on GitHub (Jun 17, 2024):

Duplicate of https://github.com/advplyr/audiobookshelf/issues/1409

@advplyr commented on GitHub (Jun 17, 2024): Duplicate of https://github.com/advplyr/audiobookshelf/issues/1409
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/audiobookshelf#2057