bug 959: Also handle negative points bug-959
authorMichael Tänzer <neo@nhng.de>
Tue, 19 Jul 2011 22:57:25 +0000 (00:57 +0200)
committerMichael Tänzer <neo@nhng.de>
Tue, 19 Jul 2011 22:57:25 +0000 (00:57 +0200)
Signed-off-by: Michael Tänzer <neo@nhng.de>
www/wot.php

index 1941861..7fa572f 100644 (file)
                
                if (intval($_POST['points']) > $max) {
                        $awarded = $newpoints = $max;
+               } elseif (intval($_POST['points']) < 0) {
+                       $awarded = $newpoints = 0;
                } else {
                        $awarded = $newpoints = intval($_POST['points']);
                }