Commit 6b7472b0 authored by Luke081515's avatar Luke081515

Fix review

* Maxlag was set wrongly
* unapprove was a problem
parent 1a38ed8e
Pipeline #1566 passed with stages
in 2 minutes and 27 seconds
......@@ -780,11 +780,13 @@ class Core extends Password {
public function review($revid, $comment = "", $unapprove = 0) {
$token = $this->requireToken();
$request = "action=review&format=json&assert=" . $this->assert .
"&maxlag=" . $maxlag .
"&maxlag=" . $this->maxlag .
"&revid=" . urlencode($revid) .
"&unapprove=" . urlencode($unapprove) .
"&comment=" . urlencode($comment) .
"&token=" . urlencode($token);
if ($unapprove) {
$request = $request . "&unapprove=1";
}
$result = $this->httpRequest($request, $this->job);
$result = json_decode($result, true);
if (array_key_exists("error", $result)) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment