From 7fd7b5474373d779fb633c176f79e1e66eb5f9e4 Mon Sep 17 00:00:00 2001 From: Martin Donnelly Date: Tue, 5 Sep 2017 12:12:42 +0100 Subject: [PATCH] Limit fx requests until Sept 18th as i've gone over :/ --- lib/fx.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/lib/fx.js b/lib/fx.js index e595af3..d3e2252 100644 --- a/lib/fx.js +++ b/lib/fx.js @@ -47,8 +47,12 @@ function getFx() { function updateFX() { logger.warn('updateBitcoin'); - getFx(); + const now = new Date(); + + if (now.getTime() > 1505696400000) + getFx(); + const mod = delay - (now.getTime() % delay); let fxUpdateFn = () => {