Fix wish not creatable
This commit is contained in:
parent
49d72886e6
commit
a840c29c85
1 changed files with 2 additions and 2 deletions
|
@ -95,7 +95,7 @@ switch ($_SERVER['REQUEST_METHOD']) {
|
||||||
$wish_description = Sanitiser::getText($_POST['wish_description']);
|
$wish_description = Sanitiser::getText($_POST['wish_description']);
|
||||||
$wish_image = Sanitiser::getURL($_POST['wish_image']);
|
$wish_image = Sanitiser::getURL($_POST['wish_image']);
|
||||||
$wish_url = Sanitiser::getURL($_POST['wish_url']);
|
$wish_url = Sanitiser::getURL($_POST['wish_url']);
|
||||||
$wish_priority = !empty(Sanitiser::getNumber($_POST['wish_priority'])) ? Sanitiser::getNumber($_POST['wish_priority']) : null;
|
$wish_priority = !empty($_POST['wish_priority']) ? Sanitiser::getNumber($_POST['wish_priority']) : null;
|
||||||
$wish_is_purchasable = isset($_POST['wish_is_purchasable']);
|
$wish_is_purchasable = isset($_POST['wish_is_purchasable']);
|
||||||
|
|
||||||
if (Wish::NO_IMAGE === $wish_image) {
|
if (Wish::NO_IMAGE === $wish_image) {
|
||||||
|
@ -262,7 +262,7 @@ switch ($_SERVER['REQUEST_METHOD']) {
|
||||||
* Product
|
* Product
|
||||||
*/
|
*/
|
||||||
$wish_id = $database->lastInsertId();
|
$wish_id = $database->lastInsertId();
|
||||||
$wish_price = Sanitiser::getNumber($_POST['wish_price']);
|
$wish_price = !empty($_POST['wish_price']) ? Sanitiser::getNumber($_POST['wish_price']) : null;
|
||||||
|
|
||||||
if ($wish_price > 0) {
|
if ($wish_price > 0) {
|
||||||
$database
|
$database
|
||||||
|
|
Loading…
Reference in a new issue