Skip to content

Commit

Permalink
fix(opds): display book metadata title instead of name
Browse files Browse the repository at this point in the history
  • Loading branch information
gotson committed Mar 20, 2020
1 parent 60edbe1 commit d06da57
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -251,10 +251,10 @@ class OpdsController(

private fun Book.toOpdsEntry() =
OpdsEntryAcquisition(
title = name,
title = metadata.title,
updated = lastModifiedDate?.atZone(ZoneId.systemDefault()) ?: ZonedDateTime.now(),
id = id.toString(),
content = "$name (${fileExtension().toUpperCase()}) (${fileSizeHumanReadable()})",
content = "${metadata.title} (${fileExtension().toUpperCase()}) (${fileSizeHumanReadable()})",
links = listOf(
OpdsLinkImageThumbnail("image/jpeg", "${ROUTE_BASE}books/$id/thumbnail"),
OpdsLinkImage(media.pages[0].mediaType, "${ROUTE_BASE}books/$id/pages/1"),
Expand Down

0 comments on commit d06da57

Please sign in to comment.