Completed
Push — development ( 252715...941400 )
by Thomas
44s
created
htdocs/src/Oc/Libse/Validator/IntegerValidator.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -35,6 +35,6 @@
 block discarded – undo
35 35
 
36 36
     protected function getValue($value)
37 37
     {
38
-        return (int) $value;
38
+        return (int)$value;
39 39
     }
40 40
 }
Please login to merge, or discard this patch.
htdocs/lib2/logic/gis.class.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -29,7 +29,7 @@  discard block
 block discarded – undo
29 29
         // number of points in the polygon
30 30
         $n = count($polygon);
31 31
         $poly1 = $polygon[0];
32
-        for ($i = 1; $i <= $n; $i ++) {
32
+        for ($i = 1; $i <= $n; $i++) {
33 33
             $poly1XY = explode(' ', $poly1);
34 34
             $poly1x = $poly1XY[0];
35 35
             $poly1y = $poly1XY[1];
@@ -44,7 +44,7 @@  discard block
 block discarded – undo
44 44
                         if ($poly1y != $poly2y) {
45 45
                             $xinters = ($py - $poly1y) * ($poly2x - $poly1x) / ($poly2y - $poly1y) + $poly1x;
46 46
                             if ($poly1x == $poly2x || $px <= $xinters) {
47
-                                $counter ++;
47
+                                $counter++;
48 48
                             }
49 49
                         }
50 50
                     }
Please login to merge, or discard this patch.
htdocs/lib2/pager.class.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -59,7 +59,7 @@
 block discarded – undo
59 59
             $to_page = min($last_page, max($first_page, $current_page - $lrspan) + $this->max_pages_shown - 1);
60 60
             $from_page = max($first_page, $to_page - $this->max_pages_shown + 1);
61 61
 
62
-            for ($page = $from_page; $page <= $to_page; $page ++) {
62
+            for ($page = $from_page; $page <= $to_page; $page++) {
63 63
                 if ($page == $current_page) {
64 64
                     $pages[$page] = false;
65 65
                 } else {
Please login to merge, or discard this patch.
htdocs/lib2/sqldebugger.class.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -74,7 +74,7 @@
 block discarded – undo
74 74
                     break;
75 75
                 }
76 76
                 $command['result'][] = $r;
77
-                $c ++;
77
+                $c++;
78 78
             }
79 79
             sql_free_result($rs);
80 80
 
Please login to merge, or discard this patch.
htdocs/newcachesrest.php 1 patch
Spacing   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -14,8 +14,7 @@
 block discarded – undo
14 14
 $tpl->caching = true;
15 15
 $tpl->cache_lifetime = 3600;
16 16
 
17
-$country = isset($_REQUEST['usercountry']) ? $_REQUEST['usercountry'] :
18
-    (isset($_REQUEST['country']) ? $_REQUEST['country'] : $opt['page']['main_country']);
17
+$country = isset($_REQUEST['usercountry']) ? $_REQUEST['usercountry'] : (isset($_REQUEST['country']) ? $_REQUEST['country'] : $opt['page']['main_country']);
19 18
 
20 19
 if (!$tpl->is_cached()) {
21 20
     $newCaches = array();
Please login to merge, or discard this patch.
htdocs/config2/locale.inc.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -17,9 +17,9 @@  discard block
 block discarded – undo
17 17
  *                 $opt['locale']
18 18
  ***************************************************************************/
19 19
 
20
-define('OC_LOCALE_ACTIVE', 2);    // enable language and show language button in header line
21
-define('OC_LOCALE_HIDDEN', 1);    // enable language but hide language button in header line
22
-define('OC_LOCALE_DISABLED', 0);  // disable language
20
+define('OC_LOCALE_ACTIVE', 2); // enable language and show language button in header line
21
+define('OC_LOCALE_HIDDEN', 1); // enable language but hide language button in header line
22
+define('OC_LOCALE_DISABLED', 0); // disable language
23 23
 
24 24
 $opt['template']['locales']['DE']['status'] = OC_LOCALE_ACTIVE;
25 25
 $opt['template']['locales']['DE']['flag'] = 'images/flag/DE.png';
@@ -131,7 +131,7 @@  discard block
 block discarded – undo
131 131
 $opt['locale']['DE']['page']['license'] = '<a rel="license" href="%1"><img alt="Creative Commons Lizenzvertrag" style="border-width:0" src="resource2/ocstyle/images/media/cc-by-nc-nd-small.png" /></a><div style="text-align:center; margin:8px 0 0 6px;">Die <a href="articles.php?page=impressum#datalicense">Inhalte</a> von {site} stehen unter der Creative-Commons-Lizenz <a rel="license" href="%1">BY-NC-ND 3.0 DE</a>.</div>';
132 132
 $opt['locale']['DE']['helpwiki'] = 'http://wiki.opencaching.de/index.php/';
133 133
 $opt['locale']['DE']['mostly_translated'] = true;
134
-$opt['locale']['DE']['what3words'] = true;  // "beta"
134
+$opt['locale']['DE']['what3words'] = true; // "beta"
135 135
 
136 136
 $opt['locale']['IT']['format']['dateshort'] = '%d/%m/%y';
137 137
 $opt['locale']['IT']['format']['dm'] = '%d/%m';
@@ -233,7 +233,7 @@  discard block
 block discarded – undo
233 233
 $opt['locale']['SV']['page']['subtitle1'] = 'Geocaching med Opencaching';
234 234
 $opt['locale']['SV']['page']['subtitle2'] = '';
235 235
 $opt['locale']['SV']['mostly_translated'] = false;
236
-$opt['locale']['SV']['what3words'] = true;  // "beta"
236
+$opt['locale']['SV']['what3words'] = true; // "beta"
237 237
 
238 238
 $opt['locale']['NO']['format']['dateshort'] = '%d.%m.%y';
239 239
 $opt['locale']['NO']['format']['dm'] = '%d.%m.';
@@ -283,7 +283,7 @@  discard block
 block discarded – undo
283 283
 $opt['locale']['RU']['country'] = 'RU';
284 284
 $opt['locale']['RU']['primary_lang_of'] = ['RU'];
285 285
 $opt['locale']['RU']['mostly_translated'] = false;
286
-$opt['locale']['RU']['what3words'] = true;   // "beta"
286
+$opt['locale']['RU']['what3words'] = true; // "beta"
287 287
 
288 288
 $opt['locale']['DA']['format']['dateshort'] = '%d.%m.%y';
289 289
 $opt['locale']['DA']['format']['dm'] = '%d.%m.';
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/src/Oc/Util/ProcessSync.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -61,7 +61,7 @@
 block discarded – undo
61 61
             $pidDaemon = fgets($pidFile, 20);
62 62
             fclose($pidFile);
63 63
 
64
-            $pidDaemon = (int) $pidDaemon;
64
+            $pidDaemon = (int)$pidDaemon;
65 65
 
66 66
             // bad PID file, e.g. due to system malfunction while creating the file?
67 67
             if ($pidDaemon <= 0) {
Please login to merge, or discard this patch.
htdocs/lib2/Net/IDNA2.php 1 patch
Spacing   +12 added lines, -14 removed lines patch added patch discarded remove patch
@@ -2322,8 +2322,7 @@  discard block
 block discarded – undo
2322 2322
         // Forcing conversion of input to UCS4 array
2323 2323
         // If one time encoding is given, use this, else the objects property
2324 2324
         switch (($one_time_encoding) ? $one_time_encoding : $this->_api_encoding) {
2325
-            case 'utf8':
2326
-                $decoded = $this->_utf8_to_ucs4($decoded);
2325
+            case 'utf8' : $decoded = $this->_utf8_to_ucs4($decoded);
2327 2326
                 break;
2328 2327
             case 'ucs4_string':
2329 2328
                 $decoded = $this->_ucs4_string_to_ucs4($decoded);
@@ -2478,8 +2477,7 @@  discard block
 block discarded – undo
2478 2477
         // The output is UTF-8 by default, other output formats need conversion here
2479 2478
         // If one time encoding is given, use this, else the objects property
2480 2479
         switch (($one_time_encoding) ? $one_time_encoding : $this->_api_encoding) {
2481
-            case 'utf8':
2482
-                return $return;
2480
+            case 'utf8' : return $return;
2483 2481
                 break;
2484 2482
             case 'ucs4_string':
2485 2483
                 return $this->_ucs4_to_ucs4_string($this->_utf8_to_ucs4($return));
@@ -2714,12 +2712,12 @@  discard block
 block discarded – undo
2714 2712
                     break;
2715 2713
                 }
2716 2714
 
2717
-                $w = (int) ($w * ($this->_base - $t));
2715
+                $w = (int)($w * ($this->_base - $t));
2718 2716
             }
2719 2717
 
2720 2718
             $bias = $this->_adapt($idx - $old_idx, $deco_len + 1, $is_first);
2721 2719
             $is_first = false;
2722
-            $char += (int) ($idx / ($deco_len + 1));
2720
+            $char += (int)($idx / ($deco_len + 1));
2723 2721
             $idx %= ($deco_len + 1);
2724 2722
 
2725 2723
             if ($deco_len > 0) {
@@ -2746,14 +2744,14 @@  discard block
 block discarded – undo
2746 2744
      */
2747 2745
     private function _adapt($delta, $npoints, $is_first)
2748 2746
     {
2749
-        $delta = (int) ($is_first ? ($delta / $this->_damp) : ($delta / 2));
2750
-        $delta += (int) ($delta / $npoints);
2747
+        $delta = (int)($is_first ? ($delta / $this->_damp) : ($delta / 2));
2748
+        $delta += (int)($delta / $npoints);
2751 2749
 
2752 2750
         for ($k = 0; $delta > (($this->_base - $this->_tmin) * $this->_tmax) / 2; $k += $this->_base) {
2753
-            $delta = (int) ($delta / ($this->_base - $this->_tmin));
2751
+            $delta = (int)($delta / ($this->_base - $this->_tmin));
2754 2752
         }
2755 2753
 
2756
-        return (int) ($k + ($this->_base - $this->_tmin + 1) * $delta / ($delta + $this->_skew));
2754
+        return (int)($k + ($this->_base - $this->_tmin + 1) * $delta / ($delta + $this->_skew));
2757 2755
     }
2758 2756
 
2759 2757
     /**
@@ -2899,8 +2897,8 @@  discard block
 block discarded – undo
2899 2897
 
2900 2898
         $result = [];
2901 2899
         $T = $this->_tbase + $sindex % $this->_tcount;
2902
-        $result[] = (int) ($this->_lbase + $sindex / $this->_ncount);
2903
-        $result[] = (int) ($this->_vbase + ($sindex % $this->_ncount) / $this->_tcount);
2900
+        $result[] = (int)($this->_lbase + $sindex / $this->_ncount);
2901
+        $result[] = (int)($this->_vbase + ($sindex % $this->_ncount) / $this->_tcount);
2904 2902
 
2905 2903
         if ($T != $this->_tbase) {
2906 2904
             $result[] = $T;
@@ -3141,7 +3139,7 @@  discard block
 block discarded – undo
3141 3139
                     throw new UnexpectedValueException('This might be UTF-8, but I don\'t understand it at byte ' . $k);
3142 3140
                 }
3143 3141
                 if ('add' == $mode) {
3144
-                    $output[$out_len] = (int) $v;
3142
+                    $output[$out_len] = (int)$v;
3145 3143
                     ++$out_len;
3146 3144
                     continue;
3147 3145
                 }
@@ -3361,7 +3359,7 @@  discard block
 block discarded – undo
3361 3359
             return mb_strlen($string, '8bit');
3362 3360
         }
3363 3361
 
3364
-        return strlen((binary) $string);
3362
+        return strlen((binary)$string);
3365 3363
     }
3366 3364
 
3367 3365
     // }}}}
Please login to merge, or discard this patch.