From 95defedf08fd683c75d99a1c4bbc76d861ade58c Mon Sep 17 00:00:00 2001 From: Romain Quetiez Date: Mon, 27 Apr 2015 09:39:41 +0000 Subject: [PATCH] Improved the symptom when an error occurs in the "apply stimulus form". The symptom used to be: Object could not be written; unknown error. Now it will give the error message (e.g. Missing query arguments) so as to help in determining what's going on. SVN:trunk[3567] --- pages/UI.php | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/pages/UI.php b/pages/UI.php index 4aac8bd4c6..cb89bab6be 100644 --- a/pages/UI.php +++ b/pages/UI.php @@ -1474,8 +1474,7 @@ EOF // Rollback to the previous state... by reloading the object from the database and applying the modifications again $oObj = MetaModel::GetObject(get_class($oObj), $oObj->GetKey()); $oObj->UpdateObjectFromPostedForm('', array_keys($aExpectedAttributes), $sTargetState); - $aData = $e->getContextData(); - $sIssues = (array_key_exists('issues', $aData)) ? $aData['issues'] : 'Unknown error...'; + $sIssues = $e->getMessage(); } } else