Fix minor bug in admin towns form
This commit is contained in:
parent
30588252d8
commit
f80cb7cd5b
|
@ -318,7 +318,7 @@ function edittown($id)
|
|||
if ($mp < 0) $errors[] = "Map price must be a number greater than or equal to 0.";
|
||||
if ($tp < 0) $errors[] = "Travel points must be a number greater than or equal to 0.";
|
||||
|
||||
if ($errors == 0) {
|
||||
if (count($errors) === 0) {
|
||||
db()->query('UPDATE towns SET name=?, latitude=?, longitude=?, innprice=?, mapprice=?, travelpoints=?, itemslist=? WHERE id=?;', [
|
||||
$n, $la, $lo, $ip, $mp, $tp, $il, $id
|
||||
]);
|
||||
|
|
Loading…
Reference in New Issue
Block a user