Skip to content

Commit bcdec44

Browse files
Update getFilt.php
+flaggedrevs
1 parent 25afd64 commit bcdec44

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

php/getFilt.php

+3-3
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@
1616
}
1717

1818
$username = $_GET['username'];
19-
2019
$ts_pw = posix_getpwuid(posix_getuid());
2120
$ts_mycnf = parse_ini_file("/data/project/swviewer/security/replica.my.cnf");
2221
$db = new PDO("mysql:host=tools.labsdb;dbname=s53950__SWViewer;charset=utf8", $ts_mycnf['user'], $ts_mycnf['password']);
@@ -28,11 +27,12 @@
2827
if ($q->rowCount() > 0) {
2928
$result = $q->fetchAll();
3029
$raw_result = ["blprojects" => $result[0]['blprojects'], "wikilangs" => $result[0]['wikilangs'], "swmt" => $result[0]['swmt'], "onlyanons" => $result[0]['anons'], "users" => $result[0]['users'], "wlusers" => $result[0]['wlusers'], "wlprojects" => $result[0]['wlprojects'], "namespaces" => $result[0]['namespaces'], "registered" => $result[0]['registered'], "new" => $result[0]['new'], "onlynew" => $result[0]['onlynew'], "editcount" => $result[0]['editscount'], "regdays" => $result[0]['regdays'], "oresFilter" => $result[0]['oresFilter']];
31-
$q = $db->prepare('SELECT isGlobal, isGlobalAccess, local_wikis FROM user WHERE name = :userName');
30+
$q = $db->prepare('SELECT isGlobal, isGlobalAccess, flaggedRevs, local_wikis FROM user WHERE name = :userName');
3231
$q->execute(array(':userName' => $username));
3332
$result2 = $q->fetchAll();
3433
$raw_result["isGlobal"] = $result2[0]['isGlobal'];
3534
$raw_result["isGlobalModeAccess"] = $result2[0]['isGlobalAccess'];
35+
$raw_result["flaggedRevs"] = $result2[0]['flaggedRevs'];
3636
$raw_result["local_wikis"] = $result2[0]['local_wikis'];
3737
echo json_encode($raw_result);
3838
} else
@@ -43,4 +43,4 @@
4343

4444
function check($check) {
4545
return (isset($check) && $check !== null && $check !== "") ? true : false;
46-
}
46+
}

0 commit comments

Comments
 (0)