diff --git a/public/include/pages/api/getpoolhashrate.inc.php b/public/include/pages/api/getpoolhashrate.inc.php index 6454b809..a5985d44 100644 --- a/public/include/pages/api/getpoolhashrate.inc.php +++ b/public/include/pages/api/getpoolhashrate.inc.php @@ -13,9 +13,9 @@ $user_id = $api->checkAccess($user->checkApiKey($_REQUEST['api_key']), @$_REQUES if ( ! $interval = $setting->getValue('statistics_ajax_data_interval')) $interval = 300; // Output JSON format - +$statistics->setGetCache(false); $dPoolHashrate = $statistics->getCurrentHashrate($interval); - +$statistics->setGetCache(true); echo $api->get_json($dPoolHashrate); diff --git a/public/include/pages/api/getuserhashrate.inc.php b/public/include/pages/api/getuserhashrate.inc.php index 03603c24..1b1d5250 100644 --- a/public/include/pages/api/getuserhashrate.inc.php +++ b/public/include/pages/api/getuserhashrate.inc.php @@ -14,8 +14,9 @@ $username = $user->getUsername($user_id); if ( ! $interval = $setting->getValue('statistics_ajax_data_interval')) $interval = 300; // Gather un-cached data +$statistics->setGetCache(false); $hashrate = $statistics->getUserHashrate($username, $user_id, $interval); - +$statistics->setGetCache(true); // Output JSON echo $api->get_json($hashrate);