From f622e87c10a30408b3af2a9958c821bd9c7ca9f0 Mon Sep 17 00:00:00 2001 From: jpirnay Date: Mon, 16 Feb 2026 12:19:21 +0100 Subject: [PATCH] fix: Correct multiple author display (#856) ## Summary * If an EPUB has: ``` J.R.R. Tolkien Christopher Tolkien ``` the current result for epub.author would provide : "J.R.R. TolkienChristopher Tolkien" (no separator!) * The fix will seperate multiple authors: "J.R.R. Tolkien, Christopher Tolkien" ## Additional Context * Simple fix in ContentOpfParser - I am not seeing any dependence on the wrong concatenated result. --- ### AI Usage While CrossPoint doesn't have restrictions on AI tools in contributing, please be transparent about their usage as it helps set the right context for reviewers. Did you use AI tools to help write this code? NO --- lib/Epub/Epub/parsers/ContentOpfParser.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lib/Epub/Epub/parsers/ContentOpfParser.cpp b/lib/Epub/Epub/parsers/ContentOpfParser.cpp index a88c2938..fd0708fd 100644 --- a/lib/Epub/Epub/parsers/ContentOpfParser.cpp +++ b/lib/Epub/Epub/parsers/ContentOpfParser.cpp @@ -327,6 +327,9 @@ void XMLCALL ContentOpfParser::characterData(void* userData, const XML_Char* s, } if (self->state == IN_BOOK_AUTHOR) { + if (!self->author.empty()) { + self->author.append(", "); // Add separator for multiple authors + } self->author.append(s, len); return; }