mirror of
https://github.com/blitzkit/blitzkit.git
synced 2026-10-25 19:49:50 +01:00
feat: cleaned blitzstars
This commit is contained in:
1 parent
c7821d03d2
commit
169588a211
13 files changed
+13
-65
No files matched your search
@@ -1,4 +1,4 @@
|
||||
export default function getTimeDaysAgo(period: number) {
|
||||
export default function getTimeDaysAgo(daysAgo: number) {
|
||||
const now = new Date();
|
||||
now.setHours(5, 0, 0, 0);
|
||||
|
||||
@@ -6,7 +6,7 @@ export default function getTimeDaysAgo(period: number) {
|
||||
if (now.getTime() > Date.now()) now.setDate(now.getDate() - 1);
|
||||
|
||||
// subtract the period number of days from now
|
||||
now.setDate(now.getDate() - period);
|
||||
now.setDate(now.getDate() - daysAgo);
|
||||
|
||||
return now.getTime() / 1000;
|
||||
}
|
||||
Reference in new issue
Block a user