From 7c659f9017e4acc19861d9e02b9bd93d59f5f02f Mon Sep 17 00:00:00 2001 From: Alexis Lahouze Date: Tue, 15 Jan 2013 15:05:58 +0100 Subject: [PATCH] Fixed reference issue in PHP 5.3 --- src/html/api/index.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/html/api/index.php b/src/html/api/index.php index df01b10..b6eb043 100644 --- a/src/html/api/index.php +++ b/src/html/api/index.php @@ -72,11 +72,11 @@ function addEntry() { $statement=$connection->prepare("insert into entry (value_date, operation_date, label, value, account_id, category) values (:value_date, :operation_date, :label, :value, :account_id, :category)"); $statement->bindParam("value_date", $entry['value_date']); - $statement->bindParam("operation_date", array_key_exists("operation_date", $entry) ? $entry['operation_date'] : null); + $statement->bindParam("operation_date", $entry['operation_date']); $statement->bindParam("label", $entry['label']); $statement->bindParam("value", $entry['value']); $statement->bindParam("account_id", $entry['account_id']); - $statement->bindParam("category", array_key_exists("category", $entry) ? $entry["category"] : null); + $statement->bindParam("category", $entry["category"]); $return=$statement->execute();