From 6955ae217e046cc562bf89c33fe103ad6e6ef895 Mon Sep 17 00:00:00 2001 From: Robert Sesek Date: Sun, 18 Mar 2007 05:21:24 +0000 Subject: [PATCH] r1497: In editreport.php, there's really no point in error checking and validation if we don't ever do it... --- docs/changes.txt | 1 + editreport.php | 11 +++++++++-- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/docs/changes.txt b/docs/changes.txt index a34ea3e..cfc0678 100644 --- a/docs/changes.txt +++ b/docs/changes.txt @@ -12,6 +12,7 @@ - Fixed: A SQL error would occur when saving creating a new usergroup - Fixed: In the product-level permissions screens, not all the products would always show up - Fixed: A minor display issue would occur in a rare instance when showing an error message when trying to add a version without a product +- Fixed: If any fields had invalid data in editreport.php no errors would be thrown 1.2.0 Beta 1 =============================== diff --git a/editreport.php b/editreport.php index da691b8..bf79814 100644 --- a/editreport.php +++ b/editreport.php @@ -204,8 +204,15 @@ if ($_POST['do'] == 'update') $notif->set_bug_data($bugapi->objdata, $bugapi->values); $log->add_data(false, $bugapi->values, $log->getCommonFields(), true); - - $bugapi->update(); + + if (!$message->hasErrors()) + { + $bugapi->update(); + } + else + { + $message->error(); + } // ------------------------------------------------------------------- // do diff history -- 2.22.5