aboutsummaryrefslogtreecommitdiff
path: root/src/lib/Tools/SequelSpy.svelte
diff options
context:
space:
mode:
authorFuwn <[email protected]>2023-12-13 18:57:43 -0800
committerFuwn <[email protected]>2023-12-13 18:57:43 -0800
commit2471974d79595179f3d8307adaac6c26a1548af1 (patch)
tree4966eeab17545c8591c3ba9560bdc1c085cac9d8 /src/lib/Tools/SequelSpy.svelte
parentstyle(Media): simplify statements (diff)
downloaddue.moe-2471974d79595179f3d8307adaac6c26a1548af1.tar.xz
due.moe-2471974d79595179f3d8307adaac6c26a1548af1.zip
style(Tools): simplify statements
Diffstat (limited to 'src/lib/Tools/SequelSpy.svelte')
-rw-r--r--src/lib/Tools/SequelSpy.svelte12
1 files changed, 5 insertions, 7 deletions
diff --git a/src/lib/Tools/SequelSpy.svelte b/src/lib/Tools/SequelSpy.svelte
index 1d1fca69..441585a4 100644
--- a/src/lib/Tools/SequelSpy.svelte
+++ b/src/lib/Tools/SequelSpy.svelte
@@ -10,17 +10,15 @@
let currentPrequels: Promise<MediaPrequel[]> = Promise.resolve([]) as Promise<MediaPrequel[]>;
let year = new Date().getFullYear();
let season = (() => {
- if (new Date().getMonth() >= 0 && new Date().getMonth() <= 2) {
+ if (new Date().getMonth() >= 0 && new Date().getMonth() <= 2)
return 'WINTER' as 'WINTER' | 'SPRING' | 'SUMMER' | 'FALL';
- } else if (new Date().getMonth() >= 3 && new Date().getMonth() <= 5) {
+ else if (new Date().getMonth() >= 3 && new Date().getMonth() <= 5)
return 'SPRING' as 'WINTER' | 'SPRING' | 'SUMMER' | 'FALL';
- } else if (new Date().getMonth() >= 6 && new Date().getMonth() <= 8) {
+ else if (new Date().getMonth() >= 6 && new Date().getMonth() <= 8)
return 'SUMMER' as 'WINTER' | 'SPRING' | 'SUMMER' | 'FALL';
- } else if (new Date().getMonth() >= 9 && new Date().getMonth() <= 11) {
+ else if (new Date().getMonth() >= 9 && new Date().getMonth() <= 11)
return 'FALL' as 'WINTER' | 'SPRING' | 'SUMMER' | 'FALL';
- } else {
- return 'WINTER' as 'WINTER' | 'SPRING' | 'SUMMER' | 'FALL';
- }
+ else return 'WINTER' as 'WINTER' | 'SPRING' | 'SUMMER' | 'FALL';
})();
$: currentPrequels = prequels(user, year, season);