ソースを参照

Fix stats cache time

poeti8 7 年 前
コミット
e94fa4ac76
1 ファイル変更4 行追加4 行削除
  1. 4 4
      server/utils/index.js

+ 4 - 4
server/utils/index.js

@@ -15,15 +15,15 @@ exports.isAdmin = email => config.ADMIN_EMAILS.includes(email);
 exports.getStatsCacheTime = total => {
   switch (true) {
     case total > 5000 && total < 20000:
-      return ms('1 hour');
+      return ms('1 hour') / 1000;
 
     case total < 40000:
-      return ms('3 hours');
+      return ms('3 hours') / 1000;
 
     case total > 40000:
-      return ms('6 hours');
+      return ms('6 hours') / 1000;
 
     default:
-      return ms('15 minutes');
+      return ms('15 minutes') / 1000;
   }
 };