Repos / pytaku / d5968844ce
commit d5968844ce68bdc360feb0625f564d860d1338b1
Author: Bùi Thành Nhân <hi@imnhan.com>
Date:   Tue Aug 25 22:35:33 2020 +0700

    fix setting chapter route's title

diff --git a/pyproject.toml b/pyproject.toml
index cffb1ee..8b2a08f 100644
--- a/pyproject.toml
+++ b/pyproject.toml
@@ -1,6 +1,6 @@
 [tool.poetry]
 name = "pytaku"
-version = "0.3.5"
+version = "0.3.6"
 description = "Self-hostable web-based manga reader"
 authors = ["Bùi Thành Nhân <hi@imnhan.com>"]
 license = "AGPL-3.0-only"
diff --git a/src/pytaku/static/js/routes/chapter.js b/src/pytaku/static/js/routes/chapter.js
index d98e36a..4019fe2 100644
--- a/src/pytaku/static/js/routes/chapter.js
+++ b/src/pytaku/static/js/routes/chapter.js
@@ -63,8 +63,8 @@ function Chapter(initialVNode) {
         },
       })
         .then((resp) => {
-          document.title = fullChapterName(chapter);
           chapter = resp;
+          document.title = fullChapterName(chapter);
           pendingPages = chapter.pages;
           // start loading pages, 3 at a time:
           loadNextPage();