aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/app.html11
-rw-r--r--src/lib/mangadex.ts8
2 files changed, 14 insertions, 5 deletions
diff --git a/src/app.html b/src/app.html
index c2d4576c..2ad032b3 100644
--- a/src/app.html
+++ b/src/app.html
@@ -3,10 +3,13 @@
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width" />
- <meta content="期限" property="og:title">
- <meta content="due.moe" property="og:site_name">
- <meta content="Instantly view which anime & manga on your lists have new episodes/chapters!" property="og:description">
- <meta content="https://due.moe/favicon.png" property="og:image">
+ <meta content="期限" property="og:title" />
+ <meta content="due.moe" property="og:site_name" />
+ <meta
+ content="Instantly view which anime & manga on your lists have new episodes/chapters!"
+ property="og:description"
+ />
+ <meta content="https://due.moe/favicon.png" property="og:image" />
<title>期限</title>
diff --git a/src/lib/mangadex.ts b/src/lib/mangadex.ts
index 8a3917e8..45251a4d 100644
--- a/src/lib/mangadex.ts
+++ b/src/lib/mangadex.ts
@@ -36,7 +36,13 @@ export const chapterCount = async (manga: Media): Promise<number | null> => {
return null;
}
- let lastChapter = lastChapterData['data'][0]['attributes']['chapter'];
+ let lastChapterIndex = 0;
+
+ while (lastChapterData['data'][lastChapterIndex]['attributes']['translatedLanguage'] !== 'en') {
+ lastChapterIndex += 1;
+ }
+
+ let lastChapter = lastChapterData['data'][lastChapterIndex]['attributes']['chapter'];
if (lastChapter == 0) {
lastChapter = null;