@@ -26,8 +26,9 @@ |
||
| 26 | 26 | */ |
| 27 | 27 | protected function newHandlerInstanceFor($name) |
| 28 | 28 | { |
| 29 | - if ( ! $handler = config('inbounder.gateways.' . $name)) |
|
| 30 | - throw new UndefinedGatewayException('The gateway \''.$name.'\' is not defined'); |
|
| 29 | + if ( ! $handler = config('inbounder.gateways.' . $name)) { |
|
| 30 | + throw new UndefinedGatewayException('The gateway \''.$name.'\' is not defined'); |
|
| 31 | + } |
|
| 31 | 32 | |
| 32 | 33 | return $this->app->make($handler); |
| 33 | 34 | } |
@@ -31,8 +31,9 @@ |
||
| 31 | 31 | */ |
| 32 | 32 | public function __get($name) |
| 33 | 33 | { |
| 34 | - if (array_key_exists($name, $this->attributes)) |
|
| 35 | - return $this->attributes[$name]; |
|
| 34 | + if (array_key_exists($name, $this->attributes)) { |
|
| 35 | + return $this->attributes[$name]; |
|
| 36 | + } |
|
| 36 | 37 | |
| 37 | 38 | return null; |
| 38 | 39 | } |
@@ -35,8 +35,9 @@ |
||
| 35 | 35 | */ |
| 36 | 36 | public function __get($name) |
| 37 | 37 | { |
| 38 | - if ( ! array_key_exists($name, $this->attributes)) |
|
| 39 | - throw new MissingAttributeException("The attribute $name does not exists.", 1); |
|
| 38 | + if ( ! array_key_exists($name, $this->attributes)) { |
|
| 39 | + throw new MissingAttributeException("The attribute $name does not exists.", 1); |
|
| 40 | + } |
|
| 40 | 41 | |
| 41 | 42 | return $this->attributes[$name]; |
| 42 | 43 | } |
@@ -54,8 +54,9 @@ discard block |
||
| 54 | 54 | { |
| 55 | 55 | $collection = new Collection; |
| 56 | 56 | |
| 57 | - foreach ($input as $address) |
|
| 58 | - $collection->push($this->address($address)); |
|
| 57 | + foreach ($input as $address) { |
|
| 58 | + $collection->push($this->address($address)); |
|
| 59 | + } |
|
| 59 | 60 | |
| 60 | 61 | return $collection; |
| 61 | 62 | } |
@@ -131,8 +132,9 @@ discard block |
||
| 131 | 132 | { |
| 132 | 133 | $body = $this->bodyHtml(); |
| 133 | 134 | |
| 134 | - if ($this->bodyIsText()) |
|
| 135 | - $body = $this->bodyText(); |
|
| 135 | + if ($this->bodyIsText()) { |
|
| 136 | + $body = $this->bodyText(); |
|
| 137 | + } |
|
| 136 | 138 | |
| 137 | 139 | return $body; |
| 138 | 140 | } |
@@ -186,8 +188,9 @@ discard block |
||
| 186 | 188 | { |
| 187 | 189 | $collection = new Collection; |
| 188 | 190 | |
| 189 | - foreach ($this->input('Headers') as $header) |
|
| 190 | - $collection->push(new Header($header['Name'], $header['Value'])); |
|
| 191 | + foreach ($this->input('Headers') as $header) { |
|
| 192 | + $collection->push(new Header($header['Name'], $header['Value'])); |
|
| 193 | + } |
|
| 191 | 194 | |
| 192 | 195 | return $collection; |
| 193 | 196 | } |
@@ -234,8 +237,8 @@ discard block |
||
| 234 | 237 | { |
| 235 | 238 | $collection = new Collection; |
| 236 | 239 | |
| 237 | - foreach ($this->input('Attachments') as $attachment) |
|
| 238 | - $collection->push( |
|
| 240 | + foreach ($this->input('Attachments') as $attachment) { |
|
| 241 | + $collection->push( |
|
| 239 | 242 | new Attachment( |
| 240 | 243 | $attachment['Name'], |
| 241 | 244 | ( isset($attachment['Content']) ? $attachment['Content'] : '' ), |
@@ -243,6 +246,7 @@ discard block |
||
| 243 | 246 | $attachment['ContentLength'] |
| 244 | 247 | ) |
| 245 | 248 | ); |
| 249 | + } |
|
| 246 | 250 | |
| 247 | 251 | return $collection; |
| 248 | 252 | } |