From bcfd34202654acbfe79fd0e340f54d46565da02e Mon Sep 17 00:00:00 2001 From: celogeek <65178+celogeek@users.noreply.github.com> Date: Sat, 8 Apr 2023 11:28:25 +0200 Subject: [PATCH] remove last page from toc this is already include in kindle --- internal/epub/core.go | 1 - internal/epub/templates/nav.xhtml.tmpl | 3 +-- 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/internal/epub/core.go b/internal/epub/core.go index 0a78b2f..7c3184a 100644 --- a/internal/epub/core.go +++ b/internal/epub/core.go @@ -234,7 +234,6 @@ func (e *ePub) Write() error { {"OEBPS/nav.xhtml", e.render(navTmpl, map[string]any{ "Title": title, "TOC": string(toc), - "Last": part.Images[len(part.Images)-1], })}, {"OEBPS/Text/style.css", styleTmpl}, {"OEBPS/Text/part.xhtml", e.render(partTmpl, map[string]any{ diff --git a/internal/epub/templates/nav.xhtml.tmpl b/internal/epub/templates/nav.xhtml.tmpl index 322ce44..5403194 100644 --- a/internal/epub/templates/nav.xhtml.tmpl +++ b/internal/epub/templates/nav.xhtml.tmpl @@ -9,9 +9,8 @@