Completed
Branch master (84f4f1)
by Thomas
23:30
created
htdocs/src/AppBundle/Form/UploadFieldNotesType.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -54,7 +54,7 @@
 block discarded – undo
54 54
                 ]
55 55
             );
56 56
 
57
-        $builder->addEventListener(FormEvents::PRE_SET_DATA, function (FormEvent $event) {
57
+        $builder->addEventListener(FormEvents::PRE_SET_DATA, function(FormEvent $event) {
58 58
             $data = $event->getData();
59 59
             $form = $event->getForm();
60 60
 
Please login to merge, or discard this patch.
htdocs/lib2/db.inc.php 2 patches
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -181,7 +181,7 @@  discard block
 block discarded – undo
181 181
         // & escaped?
182 182
         $escapesCount = 0;
183 183
         while ((($nextarg - $escapesCount - 1) > 0) && (substr($sql, $nextarg - $escapesCount - 1, 1) == '\\')) {
184
-            $escapesCount ++;
184
+            $escapesCount++;
185 185
         }
186 186
         if (($escapesCount % 2) === 1) {
187 187
             $nextarg++;
@@ -195,7 +195,7 @@  discard block
 block discarded – undo
195 195
                 while (preg_match('/^[0-9]{1}/', $nextchar) === 1) {
196 196
                     $arg .= $nextchar;
197 197
 
198
-                    $arglength ++;
198
+                    $arglength++;
199 199
                     $nextchar = substr($sql, $nextarg + $arglength + 1, 1);
200 200
                 }
201 201
 
@@ -221,13 +221,13 @@  discard block
 block discarded – undo
221 221
                         // strip apostroph and insert NULL
222 222
                         $filtered_sql = substr($filtered_sql, 0, strlen($filtered_sql) - 1);
223 223
                         $filtered_sql .= 'NULL';
224
-                        $sqlpos ++;
224
+                        $sqlpos++;
225 225
                     } else {
226 226
                         $filtered_sql .= 'NULL';
227 227
                     }
228 228
                 }
229 229
 
230
-                $sqlpos ++;
230
+                $sqlpos++;
231 231
             } else {
232 232
                 $arglength = 0;
233 233
                 $arg = '';
@@ -237,7 +237,7 @@  discard block
 block discarded – undo
237 237
                 while (preg_match('/^[a-zA-Z0-9_]{1}/', $nextchar) == 1) {
238 238
                     $arg .= $nextchar;
239 239
 
240
-                    $arglength ++;
240
+                    $arglength++;
241 241
                     $nextchar = substr($sql, $nextarg + $arglength + 1, 1);
242 242
                 }
243 243
 
@@ -284,12 +284,12 @@  discard block
 block discarded – undo
284 284
         $escapesCount = 0;
285 285
         while ((($nextarg - $escapesCount - 1) > 0)
286 286
             && (substr($filtered_sql, $nextarg - $escapesCount - 1, 1) == '\\')) {
287
-            $escapesCount ++;
287
+            $escapesCount++;
288 288
         }
289 289
         if (($escapesCount % 2) == 0) {
290 290
             // strip escapes of &
291 291
             $filtered_sql = substr($filtered_sql, 0, $nextarg) . '&' . substr($filtered_sql, $nextarg + 2);
292
-            $nextarg --;
292
+            $nextarg--;
293 293
         }
294 294
 
295 295
         $nextarg = strpos($filtered_sql, '\&', $nextarg + 2);
@@ -826,7 +826,7 @@  discard block
 block discarded – undo
826 826
         AND `online`= 1
827 827
         AND (TIMESTAMP(NOW())-TIMESTAMP(`last_check`)+`time_diff`<'&1')
828 828
         ORDER BY `w` DESC LIMIT 1",
829
-        - 1,
829
+        -1,
830 830
         $nMaxTimeDiff
831 831
     );
832 832
 
Please login to merge, or discard this patch.
Doc Comments   +26 added lines, -26 removed lines patch added patch discarded remove patch
@@ -346,7 +346,7 @@  discard block
 block discarded – undo
346 346
 }
347 347
 
348 348
 /**
349
- * @param $sql
349
+ * @param string $sql
350 350
  *
351 351
  * @return resource
352 352
  */
@@ -364,7 +364,7 @@  discard block
 block discarded – undo
364 364
 }
365 365
 
366 366
 /**
367
- * @param $sql
367
+ * @param string $sql
368 368
  *
369 369
  * @return resource
370 370
  */
@@ -382,7 +382,7 @@  discard block
 block discarded – undo
382 382
 }
383 383
 
384 384
 /**
385
- * @param $sql
385
+ * @param string $sql
386 386
  *
387 387
  * @return resource
388 388
  */
@@ -400,8 +400,8 @@  discard block
 block discarded – undo
400 400
 }
401 401
 
402 402
 /**
403
- * @param $sql
404
- * @param $default
403
+ * @param string $sql
404
+ * @param integer $default
405 405
  *
406 406
  * @return mixed
407 407
  */
@@ -419,8 +419,8 @@  discard block
 block discarded – undo
419 419
 }
420 420
 
421 421
 /**
422
- * @param $sql
423
- * @param $default
422
+ * @param string $sql
423
+ * @param integer $default
424 424
  *
425 425
  * @return mixed
426 426
  */
@@ -440,7 +440,7 @@  discard block
 block discarded – undo
440 440
 /**
441 441
  * @param $value
442 442
  *
443
- * @return mixed|string
443
+ * @return string
444 444
  */
445 445
 function sql_escape($value)
446 446
 {
@@ -465,7 +465,7 @@  discard block
 block discarded – undo
465 465
 /**
466 466
  * @param $value
467 467
  *
468
- * @return mixed|string
468
+ * @return string
469 469
  */
470 470
 function sql_escape_backtick($value)
471 471
 {
@@ -522,7 +522,7 @@  discard block
 block discarded – undo
522 522
 }
523 523
 
524 524
 /**
525
- * @param $bQuerySlave
525
+ * @param boolean $bQuerySlave
526 526
  * @param $sql
527 527
  * @param $default
528 528
  *
@@ -571,7 +571,7 @@  discard block
 block discarded – undo
571 571
     (includes database charset conversion)
572 572
 */
573 573
 /**
574
- * @param $rs
574
+ * @param resource $rs
575 575
  *
576 576
  * @return array
577 577
  */
@@ -611,7 +611,7 @@  discard block
 block discarded – undo
611 611
 }
612 612
 
613 613
 /**
614
- * @param $rs
614
+ * @param resource $rs
615 615
  *
616 616
  * @return array
617 617
  */
@@ -648,7 +648,7 @@  discard block
 block discarded – undo
648 648
 }
649 649
 
650 650
 /**
651
- * @param $rs
651
+ * @param resource $rs
652 652
  *
653 653
  * @return array
654 654
  */
@@ -719,7 +719,7 @@  discard block
 block discarded – undo
719 719
 }
720 720
 
721 721
 /**
722
- * @param $rs
722
+ * @param resource $rs
723 723
  *
724 724
  * @return int
725 725
  */
@@ -729,7 +729,7 @@  discard block
 block discarded – undo
729 729
 }
730 730
 
731 731
 /**
732
- * @param $table
732
+ * @param string $table
733 733
  */
734 734
 function sql_temp_table($table)
735 735
 {
@@ -761,7 +761,7 @@  discard block
 block discarded – undo
761 761
 }
762 762
 
763 763
 /**
764
- * @param $table
764
+ * @param string $table
765 765
  */
766 766
 function sql_temp_table_slave($table)
767 767
 {
@@ -784,7 +784,7 @@  discard block
 block discarded – undo
784 784
 }
785 785
 
786 786
 /**
787
- * @param $table
787
+ * @param string $table
788 788
  */
789 789
 function sql_drop_temp_table($table)
790 790
 {
@@ -827,7 +827,7 @@  discard block
 block discarded – undo
827 827
 }
828 828
 
829 829
 /**
830
- * @param $table
830
+ * @param string $table
831 831
  */
832 832
 function sql_drop_temp_table_slave($table)
833 833
 {
@@ -1227,7 +1227,7 @@  discard block
 block discarded – undo
1227 1227
 }
1228 1228
 
1229 1229
 /**
1230
- * @param $warnmessage
1230
+ * @param string $warnmessage
1231 1231
  */
1232 1232
 function sql_warn($warnmessage)
1233 1233
 {
@@ -1258,7 +1258,7 @@  discard block
 block discarded – undo
1258 1258
 
1259 1259
 /**
1260 1260
  * @param $f
1261
- * @param $rs
1261
+ * @param resource $rs
1262 1262
  * @param $table
1263 1263
  * @param bool $truncate
1264 1264
  */
@@ -1293,7 +1293,7 @@  discard block
 block discarded – undo
1293 1293
 }
1294 1294
 
1295 1295
 /**
1296
- * @param $f
1296
+ * @param resource $f
1297 1297
  * @param $table
1298 1298
  */
1299 1299
 function sql_export_table($f, $table)
@@ -1318,8 +1318,8 @@  discard block
 block discarded – undo
1318 1318
 }
1319 1319
 
1320 1320
 /**
1321
- * @param $filename
1322
- * @param $tables
1321
+ * @param string $filename
1322
+ * @param string[] $tables
1323 1323
  */
1324 1324
 function sql_export_tables_to_file($filename, $tables)
1325 1325
 {
@@ -1353,7 +1353,7 @@  discard block
 block discarded – undo
1353 1353
 }
1354 1354
 
1355 1355
 /**
1356
- * @param $f
1356
+ * @param resource $f
1357 1357
  * @param $table
1358 1358
  */
1359 1359
 function sql_export_structure($f, $table)
@@ -1372,7 +1372,7 @@  discard block
 block discarded – undo
1372 1372
 }
1373 1373
 
1374 1374
 /**
1375
- * @param $filename
1375
+ * @param string $filename
1376 1376
  * @param $table
1377 1377
  */
1378 1378
 function sql_export_structure_to_file($filename, $table)
@@ -1472,7 +1472,7 @@  discard block
 block discarded – undo
1472 1472
 
1473 1473
 // test if a function or procedure exists
1474 1474
 /**
1475
- * @param $type
1475
+ * @param string $type
1476 1476
  * @param $name
1477 1477
  *
1478 1478
  * @return bool
Please login to merge, or discard this patch.
htdocs/okapi_settings.php 1 patch
Indentation   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -33,7 +33,7 @@  discard block
 block discarded – undo
33 33
         'DATA_LICENSE_URL' => $opt['page']['absolute_url'] . $opt['logic']['license']['terms'],
34 34
         'DEBUG'            => ($opt['debug'] & DEBUG_DEVELOPER != 0),
35 35
         'DEBUG_PREVENT_SEMAPHORES'
36
-                           => !$opt['php']['semaphores'], # not available on old developer system
36
+                            => !$opt['php']['semaphores'], # not available on old developer system
37 37
         'DB_SERVER'        => $opt['db']['servername'],
38 38
         'DB_NAME'          => $opt['db']['placeholder']['db'],
39 39
         'DB_USERNAME'      => $opt['db']['username'],
@@ -54,7 +54,7 @@  discard block
 block discarded – undo
54 54
         'OC_NODE_ID'       => $opt['logic']['node']['id'],
55 55
         'OC_COOKIE_NAME'   => $opt['session']['cookiename'] . 'data',
56 56
         'OCDE_HTML_PURIFIER_SETTINGS'
57
-                           => $opt['html_purifier'],
57
+                            => $opt['html_purifier'],
58 58
         'GITHUB_ACCESS_TOKEN' => $opt['okapi']['github_access_token'],
59 59
     );
60 60
 }
Please login to merge, or discard this patch.
htdocs/config2/settings-dist.inc.php 1 patch
Spacing   +21 added lines, -21 removed lines patch added patch discarded remove patch
@@ -8,8 +8,8 @@  discard block
 block discarded – undo
8 8
  *  Do not modify this file - use settings.inc.php!
9 9
  ***************************************************************************/
10 10
 
11
-require_once __DIR__. '/locale.inc.php';
12
-require_once __DIR__. '/settings-dist-common.inc.php';
11
+require_once __DIR__ . '/locale.inc.php';
12
+require_once __DIR__ . '/settings-dist-common.inc.php';
13 13
 
14 14
 /* PHP settings
15 15
  *
@@ -108,7 +108,7 @@  discard block
 block discarded – undo
108 108
 // database placeholder
109 109
 
110 110
 // productive database with opencaching-tables
111
-$opt['db']['placeholder']['db'] = '';    // selected by default
111
+$opt['db']['placeholder']['db'] = ''; // selected by default
112 112
 
113 113
 // empty database for temporary table creation
114 114
 $opt['db']['placeholder']['tmpdb'] = '';
@@ -122,14 +122,14 @@  discard block
 block discarded – undo
122 122
 $opt['system']['maillog']['syslog_db_user'] = '';
123 123
 $opt['system']['maillog']['syslog_db_password'] = '';
124 124
 $opt['system']['maillog']['syslog_db_table'] = '';
125
-$opt['system']['maillog']['syslog_oc_host'] = '';  // 'host_name' column in syslog DB
126
-$opt['system']['maillog']['syslog_mta'] = 'postfix/smtp%';  // 'program' column in syslog DB
127
-$opt['system']['maillog']['column']['id'] = 'id';               // 'ID'
128
-$opt['system']['maillog']['column']['created'] = 'created';     // 'ReceivedAt'
125
+$opt['system']['maillog']['syslog_oc_host'] = ''; // 'host_name' column in syslog DB
126
+$opt['system']['maillog']['syslog_mta'] = 'postfix/smtp%'; // 'program' column in syslog DB
127
+$opt['system']['maillog']['column']['id'] = 'id'; // 'ID'
128
+$opt['system']['maillog']['column']['created'] = 'created'; // 'ReceivedAt'
129 129
 $opt['system']['maillog']['column']['host_name'] = 'host_name'; // 'FromHost'
130
-$opt['system']['maillog']['column']['message'] = 'message';     // 'Message'
131
-$opt['system']['maillog']['column']['program'] = 'program';     // 'SysLogTag'
132
-$opt['system']['maillog']['inactivity_warning'] = 30;   // warn after N days without new entries
130
+$opt['system']['maillog']['column']['message'] = 'message'; // 'Message'
131
+$opt['system']['maillog']['column']['program'] = 'program'; // 'SysLogTag'
132
+$opt['system']['maillog']['inactivity_warning'] = 30; // warn after N days without new entries
133 133
 
134 134
 /* cookie or session
135 135
  *
@@ -151,15 +151,15 @@  discard block
 block discarded – undo
151 151
  * 
152 152
  * other parameters may be customized
153 153
  */
154
-$opt['session']['mode'] = SAVE_COOKIE;     // don't change - other option "SAVE_SESSION" is not implemented properly
154
+$opt['session']['mode'] = SAVE_COOKIE; // don't change - other option "SAVE_SESSION" is not implemented properly
155 155
 $opt['session']['cookiename'] = 'oc_devel'; // only with SAVE_COOKIE
156 156
 $opt['session']['path'] = '/';
157
-$opt['session']['domain'] = '';    // may be overwritten by $opt['domain'][...]['cookiedomain']
157
+$opt['session']['domain'] = ''; // may be overwritten by $opt['domain'][...]['cookiedomain']
158 158
 
159 159
 /* maximum session lifetime
160 160
  */
161 161
 $opt['session']['expire']['cookie'] = 31536000; // when cookies used (default 1 year)
162
-$opt['session']['expire']['url'] = 1800;        // when no cookies used (default 30 min since last call), attention to session.js
162
+$opt['session']['expire']['url'] = 1800; // when no cookies used (default 30 min since last call), attention to session.js
163 163
 
164 164
 /* If the Referer was sent by the client and the substring was not found,
165 165
  * the embedded session id will be marked as invalid.
@@ -185,7 +185,7 @@  discard block
 block discarded – undo
185 185
 /* other template options
186 186
  *
187 187
  */
188
-$opt['page']['origin_url'] = 'http://www.opencaching.de/';  // production installation for this OC site
188
+$opt['page']['origin_url'] = 'http://www.opencaching.de/'; // production installation for this OC site
189 189
 $opt['page']['develsystem'] = false;
190 190
 $opt['page']['teampic_url'] = 'http://www.opencaching.de/images/team/';
191 191
 $opt['page']['teammember_url'] = 'http://www.opencaching.de/';
@@ -219,7 +219,7 @@  discard block
 block discarded – undo
219 219
     'newcaches' => [
220 220
         'show' => true,
221 221
         'url' => 'http://www.opencaching.de',
222
-        'urlname' => '',  // optional: show other name than the url-domain
222
+        'urlname' => '', // optional: show other name than the url-domain
223 223
     ],
224 224
 ];
225 225
 
@@ -378,7 +378,7 @@  discard block
 block discarded – undo
378 378
 
379 379
 /* license-related functions
380 380
  */
381
-$opt['logic']['license']['newusers'] = 2;  // see license constants in lib2/logic/const.inc.php
381
+$opt['logic']['license']['newusers'] = 2; // see license constants in lib2/logic/const.inc.php
382 382
 $opt['logic']['license']['admin'] = true;
383 383
 $opt['logic']['license']['disclaimer'] = false;
384 384
 $opt['logic']['license']['terms'] = 'articles.php?page=impressum#datalicense';
@@ -386,18 +386,18 @@  discard block
 block discarded – undo
386 386
 
387 387
 /* optional APIs
388 388
  */
389
-$opt['logic']['api']['email_problems']['key'] = '';   // must be set to enable
390
-$opt['logic']['api']['user_inactivity']['key'] = '';  // must be set to enable
389
+$opt['logic']['api']['email_problems']['key'] = ''; // must be set to enable
390
+$opt['logic']['api']['user_inactivity']['key'] = ''; // must be set to enable
391 391
 
392 392
 /* cache report info settings
393 393
  */
394 394
 $opt['logic']['cache_reports']['delaydays'] = 2;
395
-$opt['logic']['cache_reports']['min_processperday'] = 5;   // set to 0 to disable
396
-$opt['logic']['cache_reports']['max_processperday'] = 20;  // set to 0 to disable
395
+$opt['logic']['cache_reports']['min_processperday'] = 5; // set to 0 to disable
396
+$opt['logic']['cache_reports']['max_processperday'] = 20; // set to 0 to disable
397 397
 
398 398
 /* cronjob
399 399
  */
400
-$opt['cron']['username'] = 'apache';   // system username for cronjobs
400
+$opt['cron']['username'] = 'apache'; // system username for cronjobs
401 401
 
402 402
 /* phpbb news integration (index.php, outdated)
403 403
  *
Please login to merge, or discard this patch.
htdocs/lib2/imagebmp.inc.php 1 patch
Doc Comments   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -491,7 +491,7 @@  discard block
 block discarded – undo
491 491
 }
492 492
 
493 493
 /**
494
- * @param $byte
494
+ * @param integer $byte
495 495
  * @param $start
496 496
  * @param $len
497 497
  *
@@ -508,8 +508,8 @@  discard block
 block discarded – undo
508 508
 
509 509
 $CurrentBit = 0;
510 510
 /**
511
- * @param $f
512
- * @param $count
511
+ * @param resource $f
512
+ * @param integer $count
513 513
  *
514 514
  * @return number
515 515
  */
@@ -564,7 +564,7 @@  discard block
 block discarded – undo
564 564
 }
565 565
 
566 566
 /**
567
- * @param $n
567
+ * @param integer $n
568 568
  *
569 569
  * @return string
570 570
  */
@@ -585,7 +585,7 @@  discard block
 block discarded – undo
585 585
 
586 586
 /**
587 587
  * @param $d
588
- * @param $n
588
+ * @param integer $n
589 589
  *
590 590
  * @return string
591 591
  */
Please login to merge, or discard this patch.
htdocs/src/Oc/SmartyPlugins/prefilter.t.php 1 patch
Doc Comments   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -91,10 +91,10 @@  discard block
 block discarded – undo
91 91
  *
92 92
  */
93 93
 /**
94
- * @param $block
95
- * @param $message
94
+ * @param string $block
95
+ * @param string $message
96 96
  * @param $smarty
97
- * @param $line
97
+ * @param integer $line
98 98
  *
99 99
  * @return string
100 100
  */
@@ -268,7 +268,7 @@  discard block
 block discarded – undo
268 268
 
269 269
 /**
270 270
  * @param $haystack
271
- * @param $needles
271
+ * @param string[] $needles
272 272
  *
273 273
  * @return bool|int
274 274
  */
Please login to merge, or discard this patch.
htdocs/lib2/search/ftsearch.inc.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -199,7 +199,7 @@  discard block
 block discarded – undo
199 199
     $str = '';
200 200
 
201 201
     ftsearch_load_ignores();
202
-    for ($i = count($astr) - 1; $i >= 0; $i --) {
202
+    for ($i = count($astr) - 1; $i >= 0; $i--) {
203 203
         // ignore?
204 204
         if (array_search(mb_strtolower($astr[$i]), $ftsearch_ignores) !== false) {
205 205
             unset($astr[$i]);
@@ -254,7 +254,7 @@  discard block
 block discarded – undo
254 254
 
255 255
     // doppelte chars ersetzen
256 256
     $ordZ = ord('z');
257
-    for ($c = ord('a'); $c <= $ordZ; $c ++) {
257
+    for ($c = ord('a'); $c <= $ordZ; $c++) {
258 258
         $old_str = '';
259 259
         while ($old_str !== $str) {
260 260
             $old_str = $str;
Please login to merge, or discard this patch.
htdocs/lib2/menu.class.php 2 patches
Doc Comments   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -280,7 +280,7 @@  discard block
 block discarded – undo
280 280
     }
281 281
 
282 282
     /**
283
-     * @param $menuid
283
+     * @param integer|null $menuid
284 284
      * @param $ids
285 285
      * @param $items
286 286
      */
@@ -302,7 +302,7 @@  discard block
 block discarded – undo
302 302
     }
303 303
 
304 304
     /**
305
-     * @return array
305
+     * @return integer[]
306 306
      */
307 307
     public function GetSelectedMenuIds()
308 308
     {
Please login to merge, or discard this patch.
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -80,7 +80,7 @@  discard block
 block discarded – undo
80 80
                         'parent' => MNU_MAP
81 81
                     ];
82 82
                     $menuitem[MNU_MAP]['subitems'][] = $menu_map;
83
-                    ++ $menu_map;
83
+                    ++$menu_map;
84 84
                 }
85 85
             }
86 86
         }
@@ -107,7 +107,7 @@  discard block
 block discarded – undo
107 107
         $rsSubmenu = sqlf("SELECT `id` FROM `sys_menu` WHERE `parent`=0 ORDER BY `parent` ASC, `position` ASC");
108 108
         while ($rSubmenu = sql_fetch_assoc($rsSubmenu)) {
109 109
             $aMenu[MNU_ROOT]['subitems'][$nPos] = $rSubmenu['id'];
110
-            $nPos ++;
110
+            $nPos++;
111 111
         }
112 112
         sql_free_result($rsSubmenu);
113 113
         fwrite($f, "\n");
@@ -144,7 +144,7 @@  discard block
 block discarded – undo
144 144
             );
145 145
             while ($rSubmenu = sql_fetch_assoc($rsSubmenu)) {
146 146
                 $aMenu[$r['id']]['subitems'][$nPos] = $rSubmenu['id'];
147
-                $nPos ++;
147
+                $nPos++;
148 148
             }
149 149
             sql_free_result($rsSubmenu);
150 150
         }
Please login to merge, or discard this patch.
htdocs/lib2/rowEditor.class.php 1 patch
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -490,7 +490,7 @@
 block discarded – undo
490 490
     }
491 491
 
492 492
     /**
493
-     * @return bool
493
+     * @return boolean|null
494 494
      */
495 495
     public function getAnyChanged()
496 496
     {
Please login to merge, or discard this patch.