diff --git a/src/server/kiwix-serve.cpp b/src/server/kiwix-serve.cpp index 56dfd46..5f628fa 100644 --- a/src/server/kiwix-serve.cpp +++ b/src/server/kiwix-serve.cpp @@ -601,13 +601,14 @@ int main(int argc, char **argv) { string welcomeBooksHtml; for ( itr = booksIds.begin(); itr != booksIds.end(); ++itr ) { libraryManager.getBookById(*itr, currentBook); + if (!currentBook.path.empty() && readers.find(currentBook.getHumanReadableIdFromPath()) != readers.end()) { welcomeBooksHtml += "

" + currentBook.title + "

\ \ \
" + currentBook.description + "
" + - " \ \ \
Size: " + kiwix::beautifyInteger(atoi(currentBook.size.c_str())) + " MB (" + kiwix::beautifyInteger(atoi(currentBook.articleCount.c_str())) + " articles, " + kiwix::beautifyInteger(atoi(currentBook.mediaCount.c_str())) + " medias) \ + "
Size: " + kiwix::beautifyInteger(atoi(currentBook.size.c_str())/1024 != 0 ? atoi(currentBook.size.c_str())/1024 : 1) + " MB (" + kiwix::beautifyInteger(atoi(currentBook.articleCount.c_str())) + " articles, " + kiwix::beautifyInteger(atoi(currentBook.mediaCount.c_str())) + " medias) \ Created: " + currentBook.date + "
Author: " + currentBook.creator + "Language: " + currentBook.language + "
Publisher: " + (currentBook.publisher.empty() ? "unknown" : currentBook.publisher ) + "