[Fusionforge-commits] FusionForge branch master updated. 312fba6ebfcbb66faf3b99517d52ccdc5c09cece

Franck VILLAUME nerville at fusionforge.org
Fri Jun 28 11:29:55 CEST 2013


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, master has been updated
       via  312fba6ebfcbb66faf3b99517d52ccdc5c09cece (commit)
      from  cb86105129b6b2e3cfdef000ca2c14f9945a8ac1 (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 -----------------------------------------------------------------
commit 312fba6ebfcbb66faf3b99517d52ccdc5c09cece
Author: Franck Villaume <franck.villaume at trivialdev.com>
Date:   Fri Jun 28 11:28:05 2013 +0200

    docman: title must be at least 5 characters, fix the document creation in injectContent

diff --git a/src/common/docman/DocumentGroup.class.php b/src/common/docman/DocumentGroup.class.php
index 27a44a5..ff2220f 100644
--- a/src/common/docman/DocumentGroup.class.php
+++ b/src/common/docman/DocumentGroup.class.php
@@ -7,7 +7,7 @@
  * Copyright 2009, Roland Mas
  * Copyright 2010, Franck Villaume - Capgemini
  * Copyright (C) 2011-2012 Alain Peyrat - Alcatel-Lucent
- * Copyright 2012, Franck Villaume - TrivialDev
+ * Copyright 2012-2013, Franck Villaume - TrivialDev
  * http://fusionforge.org
  *
  * This file is part of FusionForge. FusionForge is free software;
@@ -796,8 +796,13 @@ class DocumentGroup extends Error {
 									$subGroupArrID = $this->getSubgroup(0);
 									$this->data_array['doc_group'] = $subGroupArrID[0];
 							}
+							if (strlen($dir_arr[$i]) < 5) {
+								$filename = $dir_arr[$i].' '._('(Title must be at least 5 characters.)');
+							} else {
+								$filename = $dir_arr[$i];
+							}
 							if (!$d->create($dir_arr[$i], $dir_arr_type, $directory.'/'.$dir_arr[$i], $this->getID(),
-								$dir_arr[$i], _('Injected by Zip:').date(DATE_ATOM))) {
+								$filename, _('Injected by Zip:').date(DATE_ATOM))) {
 								$this->setError($dir_arr[$i].': '.$d->getErrorMessage());
 								return false;
 							}

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

Summary of changes:
 src/common/docman/DocumentGroup.class.php |    9 +++++++--
 1 file changed, 7 insertions(+), 2 deletions(-)


hooks/post-receive
-- 
FusionForge



More information about the Fusionforge-commits mailing list