Test Failed
Push — CI ( 02428e...3e0292 )
by Adam
55:43
created
include/utils/LogicHook.php 1 patch
Doc Comments   +4 added lines, -3 removed lines patch added patch discarded remove patch
@@ -73,7 +73,7 @@  discard block
 block discarded – undo
73 73
 	/**
74 74
 	 * Static Function which returns and instance of LogicHook
75 75
 	 *
76
-	 * @return unknown
76
+	 * @return LogicHook
77 77
 	 */
78 78
 	static function initialize(){
79 79
 		if(empty($GLOBALS['logic_hook']))
@@ -153,6 +153,9 @@  discard block
 block discarded – undo
153 153
 		return $hook_array;
154 154
 	}
155 155
 
156
+	/**
157
+	 * @param string $module_dir
158
+	 */
156 159
 	public function getHooks($module_dir, $refresh = false)
157 160
 	{
158 161
 	    if($refresh || !isset(self::$hooks[$module_dir])) {
@@ -169,7 +172,6 @@  discard block
 block discarded – undo
169 172
 	 * @param string $module_dir
170 173
 	 * @param string $event
171 174
 	 * @param array $arguments
172
-	 * @param SugarBean $bean
173 175
 	 */
174 176
 	function call_custom_logic($module_dir, $event, $arguments = null){
175 177
 		// declare the hook array variable, it will be defined in the included file.
@@ -198,7 +200,6 @@  discard block
 block discarded – undo
198 200
 	 * @param array $hook_array
199 201
 	 * @param string $event
200 202
 	 * @param array $arguments
201
-	 * @param SugarBean $bean
202 203
 	 */
203 204
 	function process_hooks($hook_array, $event, $arguments){
204 205
 		// Now iterate through the array for the appropriate hook
Please login to merge, or discard this patch.
include/utils/progress_bar_utils.php 1 patch
Doc Comments   +8 added lines patch added patch discarded remove patch
@@ -92,6 +92,10 @@  discard block
 block discarded – undo
92 92
 	progress_bar_flush();
93 93
 }
94 94
 
95
+/**
96
+ * @param string $name
97
+ * @param integer $total
98
+ */
95 99
 function display_progress_bar($name,$current, $total)
96 100
 {
97 101
 	$percent = $current/$total * 100;
@@ -115,6 +119,10 @@  discard block
 block discarded – undo
115 119
 	progress_bar_flush();
116 120
 }
117 121
 
122
+/**
123
+ * @param string $name
124
+ * @param integer $total
125
+ */
118 126
 function update_progress_bar($name,$current, $total)
119 127
 {
120 128
 	$percent = $current/$total * 100;
Please login to merge, or discard this patch.
include/utils/sugar_file_utils.php 1 patch
Doc Comments   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -48,7 +48,7 @@  discard block
 block discarded – undo
48 48
  * 0777 by default.
49 49
  *
50 50
  * @param $pathname - String value of the directory to create
51
- * @param $mode - The integer value of the permissions mode to set the created directory to
51
+ * @param integer $mode - The integer value of the permissions mode to set the created directory to
52 52
  * @param $recursive - boolean value indicating whether or not to create recursive directories if needed
53 53
  * @param $context
54 54
  * @return boolean - Returns true on success false on failure
@@ -103,10 +103,10 @@  discard block
 block discarded – undo
103 103
  * 0777 by default.
104 104
  *
105 105
  * @param $filename - String value of the file to create
106
- * @param $mode - The integer value of the permissions mode to set the created file to
106
+ * @param string $mode - The integer value of the permissions mode to set the created file to
107 107
  * @param $$use_include_path - boolean value indicating whether or not to search the the included_path
108 108
  * @param $context
109
- * @return boolean - Returns a file pointer on success, false otherwise
109
+ * @return resource - Returns a file pointer on success, false otherwise
110 110
  */
111 111
 function sugar_fopen($filename, $mode, $use_include_path=false, $context=null){
112 112
 	//check to see if the file exists, if not then use touch to create it.
@@ -132,7 +132,7 @@  discard block
 block discarded – undo
132 132
  *
133 133
  * @param $filename - String value of the file to create
134 134
  * @param $data - The data to be written to the file
135
- * @param $flags - int as specifed by file_put_contents parameters
135
+ * @param integer $flags - int as specifed by file_put_contents parameters
136 136
  * @param $context
137 137
  * @return int - Returns the number of bytes written to the file, false otherwise.
138 138
  */
@@ -162,8 +162,8 @@  discard block
 block discarded – undo
162 162
  * This is an atomic version of sugar_file_put_contents.  It attempts to circumvent the shortcomings of file_put_contents
163 163
  * by creating a temporary unique file and then doing an atomic rename operation.
164 164
  *
165
- * @param $filename - String value of the file to create
166
- * @param $data - The data to be written to the file
165
+ * @param string $filename - String value of the file to create
166
+ * @param string $data - The data to be written to the file
167 167
  * @param string $mode String value of the parameter to specify the type of access you require to the file stream
168 168
  * @param boolean $use_include_path set to '1' or TRUE if you want to search for the file in the include_path too
169 169
  * @param context $context Context to pass into fopen operation
@@ -212,7 +212,7 @@  discard block
 block discarded – undo
212 212
  * @param $filename - String value of the file to create
213 213
  * @param $use_include_path - boolean value indicating whether or not to search the the included_path
214 214
  * @param $context
215
- * @return string|boolean - Returns a file data on success, false otherwise
215
+ * @return false|string - Returns a file data on success, false otherwise
216 216
  */
217 217
 function sugar_file_get_contents($filename, $use_include_path=false, $context=null){
218 218
 	//check to see if the file exists, if not then use touch to create it.
@@ -241,7 +241,7 @@  discard block
 block discarded – undo
241 241
  * may be set with the permissions specified in the configuration file (if set).
242 242
  *
243 243
  * @param $filename - The name of the file being touched.
244
- * @param $time - The touch time. If time  is not supplied, the current system time is used.
244
+ * @param integer $time - The touch time. If time  is not supplied, the current system time is used.
245 245
  * @param $atime - If present, the access time of the given filename is set to the value of atime
246 246
  * @return boolean - Returns TRUE on success or FALSE on failure.
247 247
  *
Please login to merge, or discard this patch.
include/utils/zip_utils.php 1 patch
Doc Comments   +6 added lines patch added patch discarded remove patch
@@ -48,6 +48,9 @@  discard block
 block discarded – undo
48 48
 if ( isset($GLOBALS['log']) && class_implements($GLOBALS['log'],'LoggerTemplate') ) {
49 49
     $GLOBALS['log']->deprecated('Use of PCLZip has been deprecated. Please enable the zip extension in your PHP install ( see http://www.php.net/manual/en/zip.installation.php for more details ).');
50 50
 }
51
+/**
52
+ * @param false|string $zip_dir
53
+ */
51 54
 function unzip( $zip_archive, $zip_dir, $forceOverwrite = false ){
52 55
     if( !is_dir( $zip_dir ) ){
53 56
         if (!defined('SUGAR_PHPUNIT_RUNNER'))
@@ -100,6 +103,9 @@  discard block
 block discarded – undo
100 103
     }
101 104
 }
102 105
 
106
+/**
107
+ * @param string $zip_dir
108
+ */
103 109
 function zip_dir( $zip_dir, $zip_archive ){
104 110
     $archive    = new PclZip( $zip_archive );
105 111
     $v_list     = $archive->create( $zip_dir );
Please login to merge, or discard this patch.
include/vCard.php 1 patch
Doc Comments   +29 added lines patch added patch discarded remove patch
@@ -87,9 +87,23 @@  discard block
 block discarded – undo
87 87
 	function setTitle($title){
88 88
 		$this->setProperty("TITLE",$title );
89 89
 	}
90
+
91
+	/**
92
+	 * @param string $org
93
+	 * @param string $dep
94
+	 */
90 95
 	function setORG($org, $dep){
91 96
 		$this->setProperty("ORG","$org;$dep" );
92 97
 	}
98
+
99
+	/**
100
+	 * @param string $address
101
+	 * @param string $city
102
+	 * @param string $state
103
+	 * @param string $postal
104
+	 * @param string $country
105
+	 * @param string $type
106
+	 */
93 107
 	function setAddress($address, $city, $state,$postal, $country, $type, $encoding=''){
94 108
 		if(!empty($encoding)) {
95 109
 			$encoding = ";ENCODING={$encoding}";
@@ -97,16 +111,27 @@  discard block
 block discarded – undo
97 111
 		$this->setProperty("ADR;$type$encoding",";;$address;$city;$state;$postal;$country" );
98 112
 	}
99 113
 
114
+	/**
115
+	 * @param string $first_name
116
+	 * @param string $last_name
117
+	 */
100 118
 	function setName($first_name, $last_name, $prefix){
101 119
 		$this->name = strtr($first_name.'_'.$last_name, ' ' , '_');
102 120
 		$this->setProperty('N',$last_name.';'.$first_name.';;'.$prefix );
103 121
 		$this->setProperty('FN',"$prefix $first_name $last_name");
104 122
 	}
105 123
 
124
+	/**
125
+	 * @param string $address
126
+	 */
106 127
 	function setEmail($address){
107 128
 		$this->setProperty('EMAIL;INTERNET', $address);
108 129
 	}
109 130
 
131
+	/**
132
+	 * @param string $number
133
+	 * @param string $type
134
+	 */
110 135
 	function setPhoneNumber( $number, $type)
111 136
 	{
112 137
 		if($type != 'FAX') {
@@ -116,6 +141,10 @@  discard block
 block discarded – undo
116 141
 		    $this->setProperty("TEL;WORK;$type", $number);
117 142
 		}
118 143
 	}
144
+
145
+	/**
146
+	 * @param string $date
147
+	 */
119 148
 	function setBirthDate($date){
120 149
 			$this->setProperty('BDAY',$date);
121 150
 	}
Please login to merge, or discard this patch.
include/ytree/ExtNode.php 1 patch
Doc Comments   +4 added lines patch added patch discarded remove patch
@@ -74,6 +74,10 @@
 block discarded – undo
74 74
 	//node.data object in javascript.
75 75
 	//users can add a collection of paramaters that will
76 76
 	//be passed to objects responding to tree events
77
+
78
+ 	/**
79
+ 	 * @param string $name
80
+ 	 */
77 81
  	function set_property($name, $value, $is_param=false) {
78 82
  		if(!empty($name) && ($value === 0 || !empty($value))) {
79 83
  			if ($is_param==false) {
Please login to merge, or discard this patch.
include/ytree/Node.php 1 patch
Doc Comments   +8 added lines patch added patch discarded remove patch
@@ -73,6 +73,10 @@  discard block
 block discarded – undo
73 73
 	//node.data object in javascript.
74 74
 	//users can add a collection of paramaters that will
75 75
 	//be passed to objects responding to tree events
76
+
77
+ 	/**
78
+ 	 * @param string $name
79
+ 	 */
76 80
  	function set_property($name, $value, $is_param=false) {
77 81
  		if(!empty($name) && ($value === 0 || !empty($value))) {
78 82
  			if ($is_param==false) {
@@ -84,6 +88,10 @@  discard block
 block discarded – undo
84 88
  	}
85 89
  	
86 90
 	//add a child node.
91
+
92
+ 	/**
93
+ 	 * @param Node $node
94
+ 	 */
87 95
  	function add_node($node) {
88 96
   		$this->nodes[$node->uid]=$node;
89 97
   	}
Please login to merge, or discard this patch.
install/install_utils.php 1 patch
Doc Comments   +37 added lines, -2 removed lines patch added patch discarded remove patch
@@ -56,6 +56,7 @@  discard block
 block discarded – undo
56 56
  * Calls a custom function (if it exists) based on the first parameter,
57 57
  *   and returns result of function call, or 'undefined' if the function doesn't exist
58 58
  * @param string function name to call in custom install hooks
59
+ * @param string $function_name
59 60
  * @return mixed function call result, or 'undefined'
60 61
  */
61 62
 function installerHook($function_name, $options = array()){
@@ -1267,6 +1268,9 @@  discard block
 block discarded – undo
1267 1268
     return $ret_val;
1268 1269
 }
1269 1270
 
1271
+/**
1272
+ * @param string $start_file
1273
+ */
1270 1274
 function recursive_make_writable($start_file)
1271 1275
     {
1272 1276
     $ret_val = make_writable($start_file);
@@ -1366,6 +1370,9 @@  discard block
 block discarded – undo
1366 1370
 }
1367 1371
 
1368 1372
 
1373
+/**
1374
+ * @param string $name
1375
+ */
1369 1376
 function print_debug_array( $name, $debug_array ){
1370 1377
     ksort( $debug_array );
1371 1378
 
@@ -1537,7 +1544,7 @@  discard block
 block discarded – undo
1537 1544
  * it will addd to the return array
1538 1545
  *
1539 1546
  * @param intput_array haystack to check
1540
- * @param needles list of needles to search for
1547
+ * @param needles string[] of needles to search for
1541 1548
  * @param output_array the array to add the keys to
1542 1549
  */
1543 1550
 function copyFromArray($input_array, $needles, $output_array){
@@ -1555,7 +1562,7 @@  discard block
 block discarded – undo
1555 1562
  * puts it into the cache/upload dir to be handed off to langPackUnpack();
1556 1563
  *
1557 1564
  * @param object file UploadFile object
1558
- * @return bool true if successful
1565
+ * @return null|boolean true if successful
1559 1566
  */
1560 1567
 function langPackFinalMove($file) {
1561 1568
     global $sugar_config;
@@ -1567,6 +1574,12 @@  discard block
 block discarded – undo
1567 1574
     return true;
1568 1575
 }
1569 1576
 
1577
+/**
1578
+ * @param string $type
1579
+ * @param string $manifest
1580
+ * @param string $license_file
1581
+ * @param string $clean_file
1582
+ */
1570 1583
 function getLicenseDisplay($type, $manifest, $zipFile, $next_step, $license_file, $clean_file) {
1571 1584
     return PackageManagerDisplay::getLicenseDisplay($license_file, 'install.php', $next_step, $zipFile, $type, $manifest, $clean_file);
1572 1585
 }
@@ -1578,6 +1591,8 @@  discard block
 block discarded – undo
1578 1591
  * @param string manifest path to manifest file
1579 1592
  * @param string zipFile path to uploaded zip file
1580 1593
  * @param int nextstep current step
1594
+ * @param string $type
1595
+ * @param string $manifest
1581 1596
  * @return string ret <form> for this package
1582 1597
  */
1583 1598
 function getPackButton($type, $manifest, $zipFile, $next_step, $uninstallable='Yes', $showButtons=true) {
@@ -1749,6 +1764,9 @@  discard block
 block discarded – undo
1749 1764
 }
1750 1765
 
1751 1766
 if ( !function_exists('extractFile') ) {
1767
+/**
1768
+ * @return string
1769
+ */
1752 1770
 function extractFile( $zip_file, $file_in_zip, $base_tmp_upgrade_dir){
1753 1771
     $my_zip_dir = mk_temp_dir( $base_tmp_upgrade_dir );
1754 1772
     unzip_file( $zip_file, $file_in_zip, $my_zip_dir );
@@ -1757,6 +1775,9 @@  discard block
 block discarded – undo
1757 1775
 }
1758 1776
 
1759 1777
 if ( !function_exists('extractManifest') ) {
1778
+/**
1779
+ * @return string
1780
+ */
1760 1781
 function extractManifest( $zip_file,$base_tmp_upgrade_dir ) {
1761 1782
     return( extractFile( $zip_file, "manifest.php",$base_tmp_upgrade_dir ) );
1762 1783
 }
@@ -1997,6 +2018,10 @@  discard block
 block discarded – undo
1997 2018
 }
1998 2019
 
1999 2020
 
2021
+/**
2022
+ * @param integer $quantity
2023
+ * @param string $string
2024
+ */
2000 2025
 function add_digits($quantity, &$string, $min = 0, $max = 9) {
2001 2026
     for($i=0; $i < $quantity; $i++) {
2002 2027
         $string .= mt_rand($min,$max);
@@ -2014,6 +2039,11 @@  discard block
 block discarded – undo
2014 2039
     return $phone;
2015 2040
 }
2016 2041
 
2042
+/**
2043
+ * @param integer $year
2044
+ * @param integer $mnth
2045
+ * @param integer $day
2046
+ */
2017 2047
 function create_date($year=null,$mnth=null,$day=null)
2018 2048
 {
2019 2049
     global $timedate;
@@ -2028,6 +2058,11 @@  discard block
 block discarded – undo
2028 2058
     return $timedate->nowDb();
2029 2059
 }
2030 2060
 
2061
+/**
2062
+ * @param integer $hr
2063
+ * @param integer $min
2064
+ * @param integer $sec
2065
+ */
2031 2066
 function create_time($hr=null,$min=null,$sec=null)
2032 2067
 {
2033 2068
     global $timedate;
Please login to merge, or discard this patch.
install/installConfig.php 1 patch
Doc Comments   +12 added lines, -6 removed lines patch added patch discarded remove patch
@@ -85,6 +85,9 @@  discard block
 block discarded – undo
85 85
 class InstallLayout
86 86
 {
87 87
 
88
+    /**
89
+     * @param string $name
90
+     */
88 91
     public static function getSelect($name, $options, $default) {
89 92
         $out = "<select name=\"$name\">";
90 93
         foreach($options as $key => $value) {
@@ -117,7 +120,7 @@  discard block
 block discarded – undo
117 120
 
118 121
     /**
119 122
      * @param $title page title
120
-     * @param $styles linked css files (string)
123
+     * @param string $styles linked css files (string)
121 124
      * @param $scripts linked javascript files (string)
122 125
      * @return string Install page layout header
123 126
      */
@@ -138,11 +141,11 @@  discard block
 block discarded – undo
138 141
 
139 142
 
140 143
     /**
141
-     * @param $name form tag name
142
-     * @param $id form tag id
144
+     * @param string $name form tag name
145
+     * @param string $id form tag id
143 146
      * @param $errs form errors
144 147
      * @param $title form header line
145
-     * @param $items form items (string)
148
+     * @param string $items form items (string)
146 149
      * @param $controlls form controll buttons (string)
147 150
      * @return string
148 151
      */
@@ -178,8 +181,8 @@  discard block
 block discarded – undo
178 181
 
179 182
 
180 183
     /**
181
-     * @param $header install page head
182
-     * @param $form install page form step
184
+     * @param string $header install page head
185
+     * @param string $form install page form step
183 186
      * @return string install page
184 187
      */
185 188
     private function getOutput($header, $form, $sugar_md, $mod_strings)
@@ -1088,6 +1091,9 @@  discard block
 block discarded – undo
1088 1091
         return $out;
1089 1092
     }
1090 1093
 
1094
+    /**
1095
+     * @param string $formId
1096
+     */
1091 1097
     private function getFormControlls($mod_strings, $formId) {
1092 1098
         $out =<<<EOQ
1093 1099
         <div id="checkingDiv" style="display:none">
Please login to merge, or discard this patch.