[Fusionforge-commits] r19315 - in trunk/src/www: people snippet

Marc-Etienne VARGENAU vargenau at fusionforge.org
Fri Feb 28 16:36:16 CET 2014


Author: vargenau
Date: 2014-02-28 16:36:16 +0100 (Fri, 28 Feb 2014)
New Revision: 19315

Modified:
   trunk/src/www/people/helpwanted-latest.php
   trunk/src/www/snippet/delete.php
   trunk/src/www/snippet/detail.php
   trunk/src/www/snippet/snippet_utils.php
Log:
Use default parameter

Modified: trunk/src/www/people/helpwanted-latest.php
===================================================================
--- trunk/src/www/people/helpwanted-latest.php	2014-02-28 15:35:48 UTC (rev 19314)
+++ trunk/src/www/people/helpwanted-latest.php	2014-02-28 15:36:16 UTC (rev 19315)
@@ -45,4 +45,4 @@
 			array(),30);
 echo people_show_job_list($result) . '</p>';
 
-people_footer(array());
+people_footer();

Modified: trunk/src/www/snippet/delete.php
===================================================================
--- trunk/src/www/snippet/delete.php	2014-02-28 15:35:48 UTC (rev 19314)
+++ trunk/src/www/snippet/delete.php	2014-02-28 15:36:16 UTC (rev 19315)
@@ -47,7 +47,7 @@
 					array(user_getid(), $snippet_package_version_id));
 		if (!$result || db_numrows($result) < 1) {
 			echo '<p class="error">'._('Error: Only the creator of a package version can delete snippets from it.').'</p>';
-			snippet_footer(array());
+			snippet_footer();
 			exit;
 		} else {
 
@@ -59,11 +59,11 @@
 							$snippet_package_version_id));
 			if (!$result || db_affected_rows($result) < 1) {
 				echo '<p class="error">'._('Error: That snippet does not exist in this package.').'</p>';
-				snippet_footer(array());
+				snippet_footer();
 				exit;
 			} else {
 				echo '<p class="feedback">'._('Item Removed From Package').'</p>';
-				snippet_footer(array());
+				snippet_footer();
 				exit;
 			}
 		}
@@ -79,7 +79,7 @@
 					array($snippet_version_id, user_getid()));
 		if (!$result || db_numrows($result) < 1) {
 			echo '<p class="error">'._('Error: That snippet does not exist.').'</p>';
-			snippet_footer(array());
+			snippet_footer();
 			exit;
 		} else {
 			$snippet_id=db_result($result,0,'snippet_id');
@@ -98,7 +98,7 @@
 			}
 
 			echo '<p class="feedback">'._('Snippet Removed').'</p>';
-			snippet_footer(array());
+			snippet_footer();
 			exit;
 		}
 
@@ -116,7 +116,7 @@
 		if (!$result || db_numrows($result) < 1) {
 			//they don't own it or it's not found
 			echo '<p class="error">'._('Error: Only the creator of a package version can delete it.').'</p>';
-			snippet_footer(array());
+			snippet_footer();
 			exit;
 		} else {
 			$snippet_package_id=db_result($result,0,'snippet_package_id');
@@ -142,7 +142,7 @@
 				$result=db_query_params("DELETE FROM snippet_package WHERE snippet_package_id=$1", array($snippet_package_id));
 			}
 			echo '<p class="feedback">'._('Package Removed').'</p>';
-			snippet_footer(array());
+			snippet_footer();
 			exit;
 		}
 	} else {

Modified: trunk/src/www/snippet/detail.php
===================================================================
--- trunk/src/www/snippet/detail.php	2014-02-28 15:35:48 UTC (rev 19314)
+++ trunk/src/www/snippet/detail.php	2014-02-28 15:36:16 UTC (rev 19315)
@@ -208,7 +208,7 @@
 	snippet_header(array('title'=>_('Snippet Library')));
 	snippet_show_package_details($id);
 	snippet_show_package_snippets($id);
-	snippet_footer(array());
+	snippet_footer();
 
 } else {
 

Modified: trunk/src/www/snippet/snippet_utils.php
===================================================================
--- trunk/src/www/snippet/snippet_utils.php	2014-02-28 15:35:48 UTC (rev 19314)
+++ trunk/src/www/snippet/snippet_utils.php	2014-02-28 15:36:16 UTC (rev 19315)
@@ -121,7 +121,7 @@
 	echo '</p>';
 }
 
-function snippet_footer($params) {
+function snippet_footer($params = array()) {
 	global $HTML;
 	$HTML->footer($params);
 }




More information about the Fusionforge-commits mailing list