This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "FusionForge".

The branch, 6.1 has been updated
       via  63088c1a2e8f419180ce39f10cfd6ec3ff2acf36 (commit)
      from  2dece158b9917c8cbe0e0fd6c10e4245e67eece9 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
https://scm.fusionforge.org/anonscm/gitweb/?p=fusionforge/fusionforge.git;a=commitdiff;h=63088c1a2e8f419180ce39f10cfd6ec3ff2acf36

commit 63088c1a2e8f419180ce39f10cfd6ec3ff2acf36
Author: Franck Villaume <[email protected]>
Date:   Wed Oct 11 22:17:22 2017 +0200

    tracker admin, customfield: protect missing default value on post

diff --git a/src/common/tracker/actions/admin-updates.php 
b/src/common/tracker/actions/admin-updates.php
index 1b79c28..447fa2b 100644
--- a/src/common/tracker/actions/admin-updates.php
+++ b/src/common/tracker/actions/admin-updates.php
@@ -706,10 +706,14 @@ if (getStringFromRequest('add_extrafield')) {
                        $is_default =  getArrayFromRequest('is_default');
                        $is_default = array_keys($is_default);
                }
-               if ($ac->setDefaultValues($is_default)) {
-                       $feedback .= _('Default value(s) Updated');
+               if ($is_default) {
+                       if ($ac->setDefaultValues($is_default)) {
+                               $feedback .= _('Default value(s) Updated');
+                       } else {
+                               $error_msg .= _('Update default value(s) 
failed')._(': ').$ac->getErrorMessage();
+                       }
                } else {
-                       $error_msg .= _('Update default value(s) failed')._(': 
').$ac->getErrorMessage();
+                       $warning_msg .= _('No default value to set.');
                }
        }
 

-----------------------------------------------------------------------

Summary of changes:
 src/common/tracker/actions/admin-updates.php | 10 +++++++---
 1 file changed, 7 insertions(+), 3 deletions(-)


hooks/post-receive
-- 
FusionForge

_______________________________________________
Fusionforge-commits mailing list
[email protected]
http://lists.fusionforge.org/cgi-bin/mailman/listinfo/fusionforge-commits

Reply via email to