bug 1003: Doh, for copy and paste.
authorMichael Tänzer <neo@nhng.de>
Tue, 8 May 2012 14:56:34 +0000 (16:56 +0200)
committerMichael Tänzer <neo@nhng.de>
Tue, 8 May 2012 14:56:34 +0000 (16:56 +0200)
Signed-off-by: Michael Tänzer <neo@nhng.de>
scripts/resetpermissions.php [changed mode: 0644->0755]

old mode 100644 (file)
new mode 100755 (executable)
index f97ad9d..055e36a
@@ -40,11 +40,11 @@ foreach ($flags as $flag) {
                echo "$row[fname] $row[lname] $row[email]";
                
                $update = "update `users` set `$flag` = 0 where `id` = $row[id]";
-               if(! $res = mysql_query($query) ) {
+               if(! $res2 = mysql_query($update) ) {
                        echo " NOT RESET!!!\n";
                        fwrite(STDERR,
-                                       "MySQL query for flag $flag failed:\n".
-                                       "\"$query\"\n".
+                                       "MySQL query for $flag flag reset on user $row[id] failed:\n".
+                                       "\"$update\"\n".
                                        mysql_error()
                        );