fixing issue mentioned in #145 with payouts

This commit is contained in:
Sebastian Grewe 2013-09-12 13:22:39 +02:00
parent 62c0641131
commit 5e1c3ae372

View File

@ -70,7 +70,7 @@ class Share {
**/
public function getRoundShares($previous_upstream=0, $current_upstream) {
$stmt = $this->mysqli->prepare("SELECT
ROUND(IFNULL(SUM(IF(difficulty=0, POW(2, (" . $this->config['difficulty'] . " - 16)), difficulty)), 0) / POW(2, (" . $this->config['difficulty'] . " - 16)), 0) AS total
ROUND(IFNULL(SUM(IF(difficulty=0, POW(2, (" . $this->config['difficulty'] . " - 16)), difficulty)), 0) / POW(2, (" . $this->config['difficulty'] . " - 16)), 8) AS total
FROM $this->table
WHERE our_result = 'Y'
AND id > ? AND id <= ?