@@ -103,5 +103,7 @@ |
||
| 103 | 103 | echo "\tDistance: " . $route->trip_distance . PHP_EOL; |
| 104 | 104 | echo "\tAddresses:" . PHP_EOL; |
| 105 | 105 | |
| 106 | - foreach($route->addresses as $address) echo "\t\t" . $address->address . PHP_EOL; |
|
| 107 | -} |
|
| 106 | + foreach($route->addresses as $address) { |
|
| 107 | + echo "\t\t" . $address->address . PHP_EOL; |
|
| 108 | + } |
|
| 109 | + } |
|
@@ -126,5 +126,7 @@ |
||
| 126 | 126 | echo "\tDistance: " . $route->trip_distance . PHP_EOL; |
| 127 | 127 | echo "\tAddresses:" . PHP_EOL; |
| 128 | 128 | |
| 129 | - foreach($route->addresses as $address) echo "\t\t" . $address->address . PHP_EOL; |
|
| 130 | -} |
|
| 129 | + foreach($route->addresses as $address) { |
|
| 130 | + echo "\t\t" . $address->address . PHP_EOL; |
|
| 131 | + } |
|
| 132 | + } |
|
@@ -87,8 +87,7 @@ discard block |
||
| 87 | 87 | if($n == 0 || $n == 2 || $n == 4 || $n == 5) |
| 88 | 88 | { |
| 89 | 89 | $addr_obj->tags = ['TAG001', 'TAG002']; |
| 90 | - } |
|
| 91 | - else if($n == 1 || $n == 3) |
|
| 90 | + } else if($n == 1 || $n == 3) |
|
| 92 | 91 | { |
| 93 | 92 | $addr_obj->tags = ['TAG003']; |
| 94 | 93 | } |
@@ -112,5 +111,7 @@ discard block |
||
| 112 | 111 | echo "\tDistance: " . $route->trip_distance . PHP_EOL; |
| 113 | 112 | echo "\tAddresses:" . PHP_EOL; |
| 114 | 113 | |
| 115 | - foreach($route->addresses as $address) echo "\t\t" . $address->address . PHP_EOL; |
|
| 116 | -} |
|
| 114 | + foreach($route->addresses as $address) { |
|
| 115 | + echo "\t\t" . $address->address . PHP_EOL; |
|
| 116 | + } |
|
| 117 | + } |
|
@@ -86,7 +86,9 @@ discard block |
||
| 86 | 86 | foreach ($json as $address) { |
| 87 | 87 | |
| 88 | 88 | // skip persistent |
| 89 | - if($address['address'] == '4738 BELLEVUE AVE, Louisville, KY, 40215') continue; |
|
| 89 | + if($address['address'] == '4738 BELLEVUE AVE, Louisville, KY, 40215') { |
|
| 90 | + continue; |
|
| 91 | + } |
|
| 90 | 92 | |
| 91 | 93 | $addresses[] = Address::fromArray([ |
| 92 | 94 | 'address' => $address['address'], |
@@ -112,5 +114,7 @@ discard block |
||
| 112 | 114 | echo "\tDistance: " . $route->trip_distance . PHP_EOL; |
| 113 | 115 | echo "\tAddresses:" . PHP_EOL; |
| 114 | 116 | |
| 115 | - foreach($route->addresses as $address) echo "\t\t" . $address->address . PHP_EOL; |
|
| 116 | -} |
|
| 117 | + foreach($route->addresses as $address) { |
|
| 118 | + echo "\t\t" . $address->address . PHP_EOL; |
|
| 119 | + } |
|
| 120 | + } |
|
@@ -79,8 +79,12 @@ discard block |
||
| 79 | 79 | foreach ($json as $address) { |
| 80 | 80 | |
| 81 | 81 | // skip retail |
| 82 | - if($address['address'] == '1407 MCCOY, Louisville, KY, 40215') continue; |
|
| 83 | - if($address['address'] == '4738 BELLEVUE AVE, Louisville, KY, 40215') continue; |
|
| 82 | + if($address['address'] == '1407 MCCOY, Louisville, KY, 40215') { |
|
| 83 | + continue; |
|
| 84 | + } |
|
| 85 | + if($address['address'] == '4738 BELLEVUE AVE, Louisville, KY, 40215') { |
|
| 86 | + continue; |
|
| 87 | + } |
|
| 84 | 88 | |
| 85 | 89 | $addresses[] = Address::fromArray([ |
| 86 | 90 | 'address' => $address['address'], |
@@ -107,5 +111,7 @@ discard block |
||
| 107 | 111 | echo "\tDistance: " . $route->trip_distance . PHP_EOL; |
| 108 | 112 | echo "\tAddresses:" . PHP_EOL; |
| 109 | 113 | |
| 110 | - foreach($route->addresses as $address) echo "\t\t" . $address->address . PHP_EOL; |
|
| 111 | -} |
|
| 114 | + foreach($route->addresses as $address) { |
|
| 115 | + echo "\t\t" . $address->address . PHP_EOL; |
|
| 116 | + } |
|
| 117 | + } |
|
@@ -103,5 +103,7 @@ |
||
| 103 | 103 | echo "\tDistance: " . $route->trip_distance . PHP_EOL; |
| 104 | 104 | echo "\tAddresses:" . PHP_EOL; |
| 105 | 105 | |
| 106 | - foreach($route->addresses as $address) echo "\t\t" . $address->address . PHP_EOL; |
|
| 107 | -} |
|
| 106 | + foreach($route->addresses as $address) { |
|
| 107 | + echo "\t\t" . $address->address . PHP_EOL; |
|
| 108 | + } |
|
| 109 | + } |
|
@@ -113,5 +113,7 @@ |
||
| 113 | 113 | echo "\tDistance: " . $route->trip_distance . PHP_EOL; |
| 114 | 114 | echo "\tAddresses:" . PHP_EOL; |
| 115 | 115 | |
| 116 | - foreach($route->addresses as $address) echo "\t\t" . $address->address . PHP_EOL; |
|
| 117 | -} |
|
| 116 | + foreach($route->addresses as $address) { |
|
| 117 | + echo "\t\t" . $address->address . PHP_EOL; |
|
| 118 | + } |
|
| 119 | + } |
|
@@ -20,7 +20,9 @@ |
||
| 20 | 20 | $refl = new ReflectionClass(__CLASS__); |
| 21 | 21 | foreach($refl->getConstants() AS $key => $val) |
| 22 | 22 | { |
| 23 | - if($val == $state) return $key; |
|
| 23 | + if($val == $state) { |
|
| 24 | + return $key; |
|
| 25 | + } |
|
| 24 | 26 | } |
| 25 | 27 | return 'UNKNOWN'; |
| 26 | 28 | } |