diff options
| author | Fuwn <[email protected]> | 2024-01-17 05:03:19 -0800 |
|---|---|---|
| committer | Fuwn <[email protected]> | 2024-01-17 05:03:19 -0800 |
| commit | c9054f2cba7e01850abe0f19f439b8d8eb102c29 (patch) | |
| tree | db11290ee546f24a406f2e42d526d8fbdf3646fc /src/lib/Media/Anime/Airing/Subtitled | |
| parent | fix(badges): clear category on submit (diff) | |
| download | due.moe-c9054f2cba7e01850abe0f19f439b8d8eb102c29.tar.xz due.moe-c9054f2cba7e01850abe0f19f439b8d8eb102c29.zip | |
fix(airing): adjust date for sutitles
Diffstat (limited to 'src/lib/Media/Anime/Airing/Subtitled')
| -rw-r--r-- | src/lib/Media/Anime/Airing/Subtitled/match.ts | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/src/lib/Media/Anime/Airing/Subtitled/match.ts b/src/lib/Media/Anime/Airing/Subtitled/match.ts index 74302353..33271dd6 100644 --- a/src/lib/Media/Anime/Airing/Subtitled/match.ts +++ b/src/lib/Media/Anime/Airing/Subtitled/match.ts @@ -99,7 +99,7 @@ export const injectAiringTime = (anime: Media, subsPlease: SubsPlease | null) => // const nativeUntilAiring = airingAt // ? Math.round((airingAt - Date.now() / 1000) * 100) / 100 // : undefined; - let nativeTime = new Date(airingAt ? airingAt * 1000 : 0); + const nativeTime = new Date(airingAt ? airingAt * 1000 : 0); let untilAiring; let time = new Date(airingAt ? airingAt * 1000 : 0); const nextEpisode = anime.nextAiringEpisode?.episode || 0; @@ -136,10 +136,6 @@ export const injectAiringTime = (anime: Media, subsPlease: SubsPlease | null) => } } - if (airingAt && nativeTime > time) { - [nativeTime, time] = [time, nativeTime]; - } - return { ...anime, nextAiringEpisode: { |