As per vichan upstream move locked board check to after openBoard call in handle_post. Unlike upstream , the board being locked doesn't stop reports or deletions being processed for that board, just new posts
This commit is contained in:
parent
55574162b1
commit
9b513c0900
15
post.php
15
post.php
|
@ -17,13 +17,6 @@ if (get_magic_quotes_gpc()) {
|
||||||
$_POST = strip_array($_POST);
|
$_POST = strip_array($_POST);
|
||||||
}
|
}
|
||||||
|
|
||||||
$board_locked_check = (!isset($_POST['mod']) || !$_POST['mod'])
|
|
||||||
&& ($config['board_locked']===true
|
|
||||||
|| (is_array($config['board_locked']) && in_array(strtolower($_POST['board']), $config['board_locked'])));
|
|
||||||
|
|
||||||
if ($board_locked_check){
|
|
||||||
error("Board is locked");
|
|
||||||
}
|
|
||||||
|
|
||||||
$dropped_post = false;
|
$dropped_post = false;
|
||||||
|
|
||||||
|
@ -414,6 +407,14 @@ function handle_post(){
|
||||||
if (!openBoard($post['board']))
|
if (!openBoard($post['board']))
|
||||||
error($config['error']['noboard']);
|
error($config['error']['noboard']);
|
||||||
|
|
||||||
|
$board_locked_check = (!isset($_POST['mod']) || !$_POST['mod'])
|
||||||
|
&& ($config['board_locked']===true
|
||||||
|
|| (is_array($config['board_locked']) && in_array(strtolower($_POST['board']), $config['board_locked'])));
|
||||||
|
|
||||||
|
if ($board_locked_check){
|
||||||
|
error("Board is locked");
|
||||||
|
}
|
||||||
|
|
||||||
if (!isset($_POST['name']))
|
if (!isset($_POST['name']))
|
||||||
$_POST['name'] = $config['anonymous'];
|
$_POST['name'] = $config['anonymous'];
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue