Completed
Push — master ( 2187a9...257b76 )
by Eric
03:24
created
src/CallUrlModel/WeatherModelTrait.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -165,8 +165,8 @@  discard block
 block discarded – undo
165 165
         $longitude = str_replace(",", ".", $this->longitude);
166 166
         $zLevel = $zoomLevel["zoomLevel"];
167 167
         $radius = $zoomLevel["radius"];
168
-        $script = "    window.addEventListener('load', function() {".
169
-            "        window.initMap($longitude, $latitude, $zLevel, $radius);".
168
+        $script = "    window.addEventListener('load', function() {" .
169
+            "        window.initMap($longitude, $latitude, $zLevel, $radius);" .
170 170
             "        var skycons = new Skycons({'color': 'white'});";
171 171
         $icon = $this->currently['icon'];
172 172
         $script .= "        skycons.add('icon1', '$icon');";
@@ -175,7 +175,7 @@  discard block
 block discarded – undo
175 175
             $icon = $day['icon'];
176 176
             $script .= "skycons.add('icon$time', '$icon');";
177 177
         }
178
-        $script .= "        skycons.play();".
178
+        $script .= "        skycons.play();" .
179 179
         "    });";
180 180
         return $script;
181 181
     }
@@ -191,7 +191,7 @@  discard block
 block discarded – undo
191 191
         if ($this->hourly && isset($this->hourly["data"])) {
192 192
             $this->hourly["data"] = array_slice($this->hourly["data"], 0, 12);
193 193
             $hours = count($this->hourly["data"]);
194
-            for ($i=0; $i < $hours; $i++) {
194
+            for ($i = 0; $i < $hours; $i++) {
195 195
                 setlocale(LC_ALL, 'sv_SV');
196 196
                 $time = $this->hourly["data"][$i]["time"];
197 197
                 if ($time) {
@@ -231,7 +231,7 @@  discard block
 block discarded – undo
231 231
         if ($this->pastDays["data"]) {
232 232
             setlocale(LC_ALL, 'sv_SV');
233 233
             $pastDayCount = count($this->pastDays["data"]);
234
-            for ($i=0; $i < $pastDayCount; $i++) {
234
+            for ($i = 0; $i < $pastDayCount; $i++) {
235 235
                 $pastDaysTime = $this->pastDays["data"][$i]["time"];
236 236
                 if ($pastDaysTime) {
237 237
                     $this->parseDate("pastDays", $i, $pastDaysTime);
@@ -319,7 +319,7 @@  discard block
 block discarded – undo
319 319
     public function calculateTimeMachine()
320 320
     {
321 321
         $days = array();
322
-        for ($i=1; $i < 31; $i++) {
322
+        for ($i = 1; $i < 31; $i++) {
323 323
             $date = date('c', strtotime("-$i days"));
324 324
             array_push($days, strtotime($date));
325 325
         }
@@ -394,7 +394,7 @@  discard block
 block discarded – undo
394 394
 
395 395
             $resultCount = count($apiResult);
396 396
 
397
-            for ($i=1; $i<$resultCount; $i++) {
397
+            for ($i = 1; $i < $resultCount; $i++) {
398 398
                 if ($apiResult[$i] && isset($apiResult[$i]["daily"]["data"][0])) {
399 399
                     array_push($pastDays["data"], $apiResult[$i]["daily"]["data"][0]);
400 400
                 }
Please login to merge, or discard this patch.
src/CallUrl/CallUrl.php 2 patches
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -67,7 +67,7 @@
 block discarded – undo
67 67
      * @param array $urls    [description]
68 68
      * @param array $params  [description]
69 69
      * @param array $queries [description]
70
-    *
70
+     *
71 71
      * @return array          [description]
72 72
      */
73 73
     public function fetchConcurrently($urls, $params, $queries)
Please login to merge, or discard this patch.
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -25,7 +25,7 @@  discard block
 block discarded – undo
25 25
     public function fetch($urlHost, $query)
26 26
     {
27 27
         $queryString = "?" . http_build_query($query);
28
-        $apiGet = curl_init($urlHost.$queryString);
28
+        $apiGet = curl_init($urlHost . $queryString);
29 29
 
30 30
         curl_setopt($apiGet, CURLOPT_RETURNTRANSFER, true);
31 31
 
@@ -88,7 +88,7 @@  discard block
 block discarded – undo
88 88
 
89 89
             $urlCount = count($urls);
90 90
 
91
-            for ($i=0; $i<$urlCount; $i++) {
91
+            for ($i = 0; $i < $urlCount; $i++) {
92 92
                 $url = $this->buildUrl($urls[$i], $params[$i], $queries[$i]);
93 93
                 array_push($nodes, $url);
94 94
             }
Please login to merge, or discard this patch.