@@ -105,13 +105,13 @@ |
||
| 105 | 105 | { |
| 106 | 106 | $params = [ |
| 107 | 107 | 'key' => $this->apiKey, |
| 108 | - 'location' => implode(',', [$lat, $lng]), |
|
| 108 | + 'location' => implode(',', [ $lat, $lng ]), |
|
| 109 | 109 | 'timestamp' => $timestamp, |
| 110 | 110 | ]; |
| 111 | 111 | |
| 112 | 112 | // Remove null values. |
| 113 | 113 | $params = array_filter($params); |
| 114 | 114 | |
| 115 | - return static::ENDPOINT.'?'.http_build_query($params); |
|
| 115 | + return static::ENDPOINT . '?' . http_build_query($params); |
|
| 116 | 116 | } |
| 117 | 117 | } |
@@ -50,8 +50,8 @@ discard block |
||
| 50 | 50 | parent::__construct($id); |
| 51 | 51 | |
| 52 | 52 | $this->timestamp = (int) $timestamp; |
| 53 | - $this->dateTime = new DateTimeImmutable('@'.$this->timestamp, $this); |
|
| 54 | - $this->country = $this->getLocation()['country_code']; |
|
| 53 | + $this->dateTime = new DateTimeImmutable('@' . $this->timestamp, $this); |
|
| 54 | + $this->country = $this->getLocation()[ 'country_code' ]; |
|
| 55 | 55 | } |
| 56 | 56 | |
| 57 | 57 | /** |
@@ -59,7 +59,7 @@ discard block |
||
| 59 | 59 | */ |
| 60 | 60 | public function getAbbreviation() |
| 61 | 61 | { |
| 62 | - return $this->loadInfo()['abbr']; |
|
| 62 | + return $this->loadInfo()[ 'abbr' ]; |
|
| 63 | 63 | } |
| 64 | 64 | |
| 65 | 65 | /** |
@@ -91,7 +91,7 @@ discard block |
||
| 91 | 91 | */ |
| 92 | 92 | public function getUtcOffset() |
| 93 | 93 | { |
| 94 | - return $this->loadInfo()['offset']; |
|
| 94 | + return $this->loadInfo()[ 'offset' ]; |
|
| 95 | 95 | } |
| 96 | 96 | |
| 97 | 97 | /** |
@@ -99,7 +99,7 @@ discard block |
||
| 99 | 99 | */ |
| 100 | 100 | public function isDst() |
| 101 | 101 | { |
| 102 | - return $this->loadInfo()['isdst']; |
|
| 102 | + return $this->loadInfo()[ 'isdst' ]; |
|
| 103 | 103 | } |
| 104 | 104 | |
| 105 | 105 | /** |
@@ -125,9 +125,9 @@ discard block |
||
| 125 | 125 | { |
| 126 | 126 | $transitions = $this->getTransitions($timestamp, $timestamp); |
| 127 | 127 | if (false === $transitions) { |
| 128 | - $transitions = [['abbr' => null, 'isdst' => null, 'offset' => null]]; |
|
| 128 | + $transitions = [ [ 'abbr' => null, 'isdst' => null, 'offset' => null ] ]; |
|
| 129 | 129 | } |
| 130 | 130 | |
| 131 | - return $transitions[0]; |
|
| 131 | + return $transitions[ 0 ]; |
|
| 132 | 132 | } |
| 133 | 133 | } |