Completed
Push — master ( 2d4977...3189d6 )
by Michael
10:50
created
class/adsense.php 1 patch
Doc Comments   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -92,7 +92,7 @@  discard block
 block discarded – undo
92 92
     /**
93 93
      * @param  string $key
94 94
      * @param  string $format
95
-     * @return mixed
95
+     * @return string
96 96
      */
97 97
     public function getVar($key, $format = 's')
98 98
     {
@@ -157,7 +157,7 @@  discard block
 block discarded – undo
157 157
     }
158 158
 
159 159
     /**
160
-     * @return mixed|string
160
+     * @return string
161 161
      */
162 162
     public function generateTag()
163 163
     {
Please login to merge, or discard this patch.
class/customtag.php 2 patches
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -147,7 +147,7 @@
 block discarded – undo
147 147
     }
148 148
 
149 149
     /**
150
-     * @return mixed|string
150
+     * @return string
151 151
      */
152 152
     public function generateTag()
153 153
     {
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -221,7 +221,7 @@
 block discarded – undo
221 221
             $criteria->add($criteria_language);
222 222
 
223 223
             $smartobjectPermissionsHandler = new SmartObjectPermissionHandler($this);
224
-            $granted_ids                     = $smartobjectPermissionsHandler->getGrantedItems('view');
224
+            $granted_ids = $smartobjectPermissionsHandler->getGrantedItems('view');
225 225
 
226 226
             if ($granted_ids && count($granted_ids) > 0) {
227 227
                 $criteria->add(new Criteria('customtagid', '(' . implode(', ', $granted_ids) . ')', 'IN'));
Please login to merge, or discard this patch.
class/form/elements/smartformuploadelement.php 1 patch
Doc Comments   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -12,8 +12,8 @@
 block discarded – undo
12 12
 class SmartFormUploadElement extends XoopsFormFile
13 13
 {
14 14
     /**
15
-     * @param $object
16
-     * @param $key
15
+     * @param string $object
16
+     * @param string $key
17 17
      */
18 18
     public function SmartFormFileElement($object, $key)
19 19
     {
Please login to merge, or discard this patch.
class/form/smartobjectform.php 2 patches
Doc Comments   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -306,8 +306,8 @@
 block discarded – undo
306 306
     }
307 307
 
308 308
     /**
309
-     * @param      $form_name
310
-     * @param      $form_caption
309
+     * @param      string $form_name
310
+     * @param      string $form_caption
311 311
      * @param bool $submit_button_caption
312 312
      */
313 313
     public function createButtons($form_name, $form_caption, $submit_button_caption = false)
Please login to merge, or discard this patch.
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -52,7 +52,7 @@  discard block
 block discarded – undo
52 52
      */
53 53
     public function __construct(&$target, $form_name, $form_caption, $form_action, $form_fields = null, $submit_button_caption = false, $cancel_js_action = false, $captcha = false)
54 54
     {
55
-        $this->targetObject           =& $target;
55
+        $this->targetObject           = & $target;
56 56
         $this->form_fields            = $form_fields;
57 57
         $this->_cancel_js_action      = $cancel_js_action;
58 58
         $this->_captcha               = $captcha;
@@ -91,7 +91,7 @@  discard block
 block discarded – undo
91 91
      */
92 92
     public function addCustomButton($name, $caption, $onclick = false)
93 93
     {
94
-        $custom_button_array    = array(
94
+        $custom_button_array = array(
95 95
             'name'    => $name,
96 96
             'caption' => $caption,
97 97
             'onclick' => $onclick
@@ -286,7 +286,7 @@  discard block
 block discarded – undo
286 286
 
287 287
         if ($permissions) {
288 288
             $memberHandler = xoops_getHandler('member');
289
-            $group_list     = $memberHandler->getGroupList();
289
+            $group_list = $memberHandler->getGroupList();
290 290
             asort($group_list);
291 291
             foreach ($permissions as $permission) {
292 292
                 if ($this->targetObject->isNew()) {
@@ -684,7 +684,7 @@  discard block
 block discarded – undo
684 684
     {
685 685
         foreach ($this->_elements as $eleObj) {
686 686
             if ($eleObj->getName() == $keyname) {
687
-                $ret =& $eleObj;
687
+                $ret = & $eleObj;
688 688
                 break;
689 689
             }
690 690
         }
@@ -782,7 +782,7 @@  discard block
 block discarded – undo
782 782
         $formname = $this->getName();
783 783
         $js .= "function xoopsFormValidate_{$formname}(myform) {";
784 784
         // First, output code to check required elements
785
-        $elements =& $this->getRequired();
785
+        $elements = & $this->getRequired();
786 786
         foreach ($elements as $elt) {
787 787
             $eltname    = $elt->getName();
788 788
             $eltcaption = trim($elt->getCaption());
@@ -834,7 +834,7 @@  discard block
 block discarded – undo
834 834
             }
835 835
         }
836 836
         // Now, handle custom validation code
837
-        $elements =& $this->getElements(true);
837
+        $elements = & $this->getElements(true);
838 838
         foreach ($elements as $elt) {
839 839
             if (method_exists($elt, 'renderValidationJS') && strtolower(get_class($elt)) !== 'xoopsformcheckbox') {
840 840
                 if ($eltjs = $elt->renderValidationJS()) {
Please login to merge, or discard this patch.
class/member.php 2 patches
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -237,7 +237,7 @@
 block discarded – undo
237 237
      * Creates a random number with a specified number of $digits
238 238
      *
239 239
      * @param  int $digits number of digits
240
-     * @return return int random number
240
+     * @return string int random number
241 241
      * @author xHelp Team
242 242
      *
243 243
      * @access public
Please login to merge, or discard this patch.
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -105,7 +105,7 @@  discard block
 block discarded – undo
105 105
 
106 106
         global $xoopsConfig;
107 107
 
108
-        $configHandler  = xoops_getHandler('config');
108
+        $configHandler = xoops_getHandler('config');
109 109
         $xoopsConfigUser = $configHandler->getConfigsByCat(XOOPS_CONF_USER);
110 110
         switch ($xoopsConfigUser['activation_type']) {
111 111
             case 0:
@@ -151,7 +151,7 @@  discard block
 block discarded – undo
151 151
 
152 152
         if ($notifyUser) {
153 153
             // send some notifications
154
-            $xoopsMailer =& getMailer();
154
+            $xoopsMailer = & getMailer();
155 155
             $xoopsMailer->useMail();
156 156
             $xoopsMailer->setTemplateDir(SMARTOBJECT_ROOT_PATH . 'language/' . $xoopsConfig['language'] . '/mail_template');
157 157
             $xoopsMailer->setTemplate('smartobject_notify_user_added_by_admin.tpl');
@@ -265,7 +265,7 @@  discard block
 block discarded – undo
265 265
     {
266 266
         static $randCalled = false;
267 267
         if (!$randCalled) {
268
-            mt_srand((double)microtime() * 1000000);
268
+            mt_srand((double) microtime() * 1000000);
269 269
             $randCalled = true;
270 270
         }
271 271
     }
Please login to merge, or discard this patch.
class/smartdbupdater.php 1 patch
Doc Comments   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -141,7 +141,7 @@  discard block
 block discarded – undo
141 141
     }
142 142
 
143 143
     /**
144
-     * @param $field
144
+     * @param string $field
145 145
      * @return bool
146 146
      */
147 147
     public function fieldExists($field)
@@ -623,7 +623,7 @@  discard block
 block discarded – undo
623 623
     /**
624 624
      * Use to update a table
625 625
      *
626
-     * @param object $table {@link SmartDbTable} that will be updated
626
+     * @param SmartDbTable $table {@link SmartDbTable} that will be updated
627 627
      *
628 628
      * @see SmartDbTable
629 629
      *
@@ -725,7 +725,7 @@  discard block
 block discarded – undo
725 725
     /**
726 726
      * @param $module
727 727
      * @param $item
728
-     * @return bool
728
+     * @return false|null
729 729
      */
730 730
     public function upgradeObjectItem($module, $item)
731 731
     {
Please login to merge, or discard this patch.
class/smartexport.php 2 patches
Doc Comments   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -197,7 +197,7 @@  discard block
 block discarded – undo
197 197
     /**
198 198
      * @param $val
199 199
      * @param $separator
200
-     * @param $trimFunction
200
+     * @param false|string $trimFunction
201 201
      * @return mixed|string
202 202
      */
203 203
     public function valToCsvHelper($val, $separator, $trimFunction)
@@ -248,7 +248,7 @@  discard block
 block discarded – undo
248 248
     }
249 249
 
250 250
     /**
251
-     * @param $content
251
+     * @param string $content
252 252
      */
253 253
     public function saveExportFile($content)
254 254
     {
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -203,7 +203,7 @@
 block discarded – undo
203 203
     public function valToCsvHelper($val, $separator, $trimFunction)
204 204
     {
205 205
         if ($trimFunction) {
206
-            $val = $trimFunction ($val);
206
+            $val = $trimFunction($val);
207 207
         }
208 208
         //If there is a separator (;) or a quote (") or a linebreak in the string, we need to quote it.
209 209
         $needQuote = false;
Please login to merge, or discard this patch.
class/smartmetagen.php 1 patch
Doc Comments   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -165,7 +165,7 @@  discard block
 block discarded – undo
165 165
     }
166 166
 
167 167
     /**
168
-     * @param $keywords
168
+     * @param string|boolean $keywords
169 169
      */
170 170
     public function setKeywords($keywords)
171 171
     {
@@ -173,7 +173,7 @@  discard block
 block discarded – undo
173 173
     }
174 174
 
175 175
     /**
176
-     * @param $categoryPath
176
+     * @param boolean $categoryPath
177 177
      */
178 178
     public function setCategoryPath($categoryPath)
179 179
     {
@@ -182,7 +182,7 @@  discard block
 block discarded – undo
182 182
     }
183 183
 
184 184
     /**
185
-     * @param $description
185
+     * @param boolean $description
186 186
      */
187 187
     public function setDescription($description)
188 188
     {
@@ -242,8 +242,8 @@  discard block
 block discarded – undo
242 242
     }
243 243
 
244 244
     /**
245
-     * @param $text
246
-     * @param $minChar
245
+     * @param string $text
246
+     * @param integer $minChar
247 247
      * @return array
248 248
      */
249 249
     public function findMetaKeywords($text, $minChar)
Please login to merge, or discard this patch.
class/smartobject.php 2 patches
Doc Comments   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -164,7 +164,7 @@  discard block
 block discarded – undo
164 164
     }
165 165
 
166 166
     /**
167
-     * @param        $key
167
+     * @param        string $key
168 168
      * @param        $data_type
169 169
      * @param bool   $itemName
170 170
      * @param string $form_caption
@@ -192,7 +192,7 @@  discard block
 block discarded – undo
192 192
      * @param bool   $required     set to TRUE if this variable needs to have a value set before storing the object in the table
193 193
      * @param string $form_caption caption of this variable in a {@link SmartobjectForm} and title of a column in a  {@link SmartObjectTable}
194 194
      * @param string $form_dsc     description of this variable in a {@link SmartobjectForm}
195
-     * @param mixed  $value        default value of this variable
195
+     * @param string|false  $value        default value of this variable
196 196
      */
197 197
     public function quickInitVar($key, $data_type, $required = false, $form_caption = '', $form_dsc = '', $value = null)
198 198
     {
@@ -201,7 +201,7 @@  discard block
 block discarded – undo
201 201
     }
202 202
 
203 203
     /**
204
-     * @param        $varname
204
+     * @param        string $varname
205 205
      * @param bool   $displayOnForm
206 206
      * @param string $default
207 207
      */
@@ -457,7 +457,7 @@  discard block
 block discarded – undo
457 457
     /**
458 458
      * add an error
459 459
      *
460
-     * @param      $err_str
460
+     * @param      string $err_str
461 461
      * @param bool $prefix
462 462
      * @internal param string $value error to add
463 463
      * @access   public
@@ -719,8 +719,8 @@  discard block
 block discarded – undo
719 719
 
720 720
     /**
721 721
      * @param $key
722
-     * @param $info
723
-     * @param $value
722
+     * @param string $info
723
+     * @param boolean $value
724 724
      */
725 725
     public function setVarInfo($key, $info, $value)
726 726
     {
@@ -728,7 +728,7 @@  discard block
 block discarded – undo
728 728
     }
729 729
 
730 730
     /**
731
-     * @param       $key
731
+     * @param       string $key
732 732
      * @param  bool $editor
733 733
      * @return string
734 734
      */
@@ -905,7 +905,7 @@  discard block
 block discarded – undo
905 905
      * @access public
906 906
      * @param  string $key    key of the object's variable to be returned
907 907
      * @param  string $format format to use for the output
908
-     * @return mixed  formatted value of the variable
908
+     * @return string  formatted value of the variable
909 909
      */
910 910
     public function getVar($key, $format = 's')
911 911
     {
@@ -1208,7 +1208,7 @@  discard block
 block discarded – undo
1208 1208
     }
1209 1209
 
1210 1210
     /**
1211
-     * @param $key
1211
+     * @param string $key
1212 1212
      */
1213 1213
     public function hideFieldFromForm($key)
1214 1214
     {
Please login to merge, or discard this patch.
Spacing   +12 added lines, -12 removed lines patch added patch discarded remove patch
@@ -421,7 +421,7 @@  discard block
 block discarded – undo
421 421
     public function toArray()
422 422
     {
423 423
         $ret  = array();
424
-        $vars =& $this->getVars();
424
+        $vars = & $this->getVars();
425 425
         foreach ($vars as $key => $var) {
426 426
             $value     = $this->getVar($key);
427 427
             $ret[$key] = $value;
@@ -538,7 +538,7 @@  discard block
 block discarded – undo
538 538
         }
539 539
 
540 540
         $smartPermissionsHandler = new SmartobjectPermissionHandler($this->handler);
541
-        $ret                      = $smartPermissionsHandler->getGrantedGroups($group_perm, $this->id());
541
+        $ret = $smartPermissionsHandler->getGrantedGroups($group_perm, $this->id());
542 542
 
543 543
         if (count($ret) == 0) {
544 544
             return false;
@@ -797,8 +797,8 @@  discard block
 block discarded – undo
797 797
                             $this->setErrors(sprintf(_XOBJ_ERR_REQUIRED, $k));
798 798
                             continue;
799 799
                         }
800
-                        if (isset($v['maxlength']) && strlen($cleanv) > (int)$v['maxlength']) {
801
-                            $this->setErrors(sprintf(_XOBJ_ERR_SHORTERTHAN, $k, (int)$v['maxlength']));
800
+                        if (isset($v['maxlength']) && strlen($cleanv) > (int) $v['maxlength']) {
801
+                            $this->setErrors(sprintf(_XOBJ_ERR_SHORTERTHAN, $k, (int) $v['maxlength']));
802 802
                             continue;
803 803
                         }
804 804
                         if (!$v['not_gpc']) {
@@ -827,7 +827,7 @@  discard block
 block discarded – undo
827 827
                         break;
828 828
                     case XOBJ_DTYPE_INT:
829 829
                     case XOBJ_DTYPE_TIME_ONLY:
830
-                        $cleanv = (int)$cleanv;
830
+                        $cleanv = (int) $cleanv;
831 831
                         break;
832 832
 
833 833
                     case XOBJ_DTYPE_CURRENCY:
@@ -860,7 +860,7 @@  discard block
 block discarded – undo
860 860
                             $cleanv = 'http://' . $cleanv;
861 861
                         }
862 862
                         if (!$v['not_gpc']) {
863
-                            $cleanv =& $ts->stripSlashesGPC($cleanv);
863
+                            $cleanv = & $ts->stripSlashesGPC($cleanv);
864 864
                         }
865 865
                         break;
866 866
                     case XOBJ_DTYPE_SIMPLE_ARRAY:
@@ -872,7 +872,7 @@  discard block
 block discarded – undo
872 872
                     case XOBJ_DTYPE_STIME:
873 873
                     case XOBJ_DTYPE_MTIME:
874 874
                     case XOBJ_DTYPE_LTIME:
875
-                        $cleanv = !is_string($cleanv) ? (int)$cleanv : strtotime($cleanv);
875
+                        $cleanv = !is_string($cleanv) ? (int) $cleanv : strtotime($cleanv);
876 876
                         if (!($cleanv > 0)) {
877 877
                             $cleanv = strtotime($cleanv);
878 878
                         }
@@ -881,7 +881,7 @@  discard block
 block discarded – undo
881 881
                         break;
882 882
                 }
883 883
             }
884
-            $this->cleanVars[$k] =& $cleanv;
884
+            $this->cleanVars[$k] = & $cleanv;
885 885
             unset($cleanv);
886 886
         }
887 887
         if (count($this->_errors) > 0) {
@@ -1099,10 +1099,10 @@  discard block
 block discarded – undo
1099 1099
                 }
1100 1100
                 break;
1101 1101
             case XOBJ_DTYPE_SIMPLE_ARRAY:
1102
-                $ret =& explode('|', $ret);
1102
+                $ret = & explode('|', $ret);
1103 1103
                 break;
1104 1104
             case XOBJ_DTYPE_ARRAY:
1105
-                $ret =& unserialize($ret);
1105
+                $ret = & unserialize($ret);
1106 1106
                 break;
1107 1107
             case XOBJ_DTYPE_SOURCE:
1108 1108
                 switch (strtolower($format)) {
@@ -1361,7 +1361,7 @@  discard block
 block discarded – undo
1361 1361
     public function getUrlLinkObj($key)
1362 1362
     {
1363 1363
         $smartobjectLinkurlHandler = xoops_getModuleHandler('urllink', 'smartobject');
1364
-        $urllinkid                   = $this->getVar($key) != null ? $this->getVar($key) : 0;
1364
+        $urllinkid = $this->getVar($key) != null ? $this->getVar($key) : 0;
1365 1365
         if ($urllinkid != 0) {
1366 1366
             return $smartobjectLinkurlHandler->get($urllinkid);
1367 1367
         } else {
@@ -1387,7 +1387,7 @@  discard block
 block discarded – undo
1387 1387
     public function getFileObj($key)
1388 1388
     {
1389 1389
         $smartobjectFileHandler = xoops_getModuleHandler('file', 'smartobject');
1390
-        $fileid                   = $this->getVar($key) != null ? $this->getVar($key) : 0;
1390
+        $fileid = $this->getVar($key) != null ? $this->getVar($key) : 0;
1391 1391
         if ($fileid != 0) {
1392 1392
             return $smartobjectFileHandler->get($fileid);
1393 1393
         } else {
Please login to merge, or discard this patch.