diff --git a/app/Controllers/Giftcards.php b/app/Controllers/Giftcards.php index e685177fe..5eef50a6c 100644 --- a/app/Controllers/Giftcards.php +++ b/app/Controllers/Giftcards.php @@ -174,7 +174,7 @@ class Giftcards extends Secure_Controller { $giftcard_amount = prepare_decimal($this->request->getPost('giftcard_amount')); $parsed_value = filter_var($giftcard_amount, FILTER_SANITIZE_NUMBER_FLOAT, FILTER_FLAG_ALLOW_FRACTION); - echo json_encode (['success' => $parsed_value !== false, 'giftcard_amount' => to_currency_no_money($parsed_value)]); + echo json_encode (['success' => $parsed_value !== false && $parsed_value > 0, 'giftcard_amount' => to_currency_no_money($parsed_value)]); } /**