From 5b7cf6ab93e8f281d9b9880ab6a48640d85fffd0 Mon Sep 17 00:00:00 2001 From: Sebastian Grewe Date: Sun, 19 Jan 2014 17:28:34 +0100 Subject: [PATCH] [FIX] SQL again, sigh --- public/include/classes/statistics.class.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/public/include/classes/statistics.class.php b/public/include/classes/statistics.class.php index 8687d421..327614d9 100644 --- a/public/include/classes/statistics.class.php +++ b/public/include/classes/statistics.class.php @@ -464,14 +464,14 @@ class Statistics extends Base { FROM ( SELECT id, - IF(s.difficulty = 0, POW(2, (" . $this->config['difficulty'] . " - 16)), s.difficulty) AS difficulty, + IF(difficulty = 0, POW(2, (" . $this->config['difficulty'] . " - 16)), difficulty) AS difficulty, username FROM shares WHERE time > DATE_SUB(now(), INTERVAL ? SECOND) AND our_result = 'Y' UNION SELECT share_id, - IF(s.difficulty = 0, POW(2, (" . $this->config['difficulty'] . " - 16)), s.difficulty) AS difficulty, + IF(difficulty = 0, POW(2, (" . $this->config['difficulty'] . " - 16)), difficulty) AS difficulty, username FROM shares_archive WHERE time > DATE_SUB(now(), INTERVAL ? SECOND) AND our_result = 'Y'