@@ -35,7 +35,7 @@ discard block |
||
| 35 | 35 | * @param array $settings used to pass to the Entity instance anything that would be done via DIC if it was a service |
| 36 | 36 | * @throws \InvalidArgumentException |
| 37 | 37 | */ |
| 38 | - public function __construct(eZRepository $repository, Content $content=null, Location $location=null, array $settings = array()) |
|
| 38 | + public function __construct(eZRepository $repository, Content $content = null, Location $location = null, array $settings = array()) |
|
| 39 | 39 | { |
| 40 | 40 | if ($content == null && $location == null) { |
| 41 | 41 | throw new \InvalidArgumentException('Trying to create Entity with no content or location'); |
@@ -69,7 +69,7 @@ discard block |
||
| 69 | 69 | */ |
| 70 | 70 | public function content() |
| 71 | 71 | { |
| 72 | - if($this->content == null){ |
|
| 72 | + if ($this->content == null) { |
|
| 73 | 73 | $this->content = $this->repository->getContentService()->loadContentByContentInfo($this->location->contentInfo); |
| 74 | 74 | } |
| 75 | 75 | return $this->content; |
@@ -81,7 +81,7 @@ discard block |
||
| 81 | 81 | */ |
| 82 | 82 | public function location() |
| 83 | 83 | { |
| 84 | - if($this->location == null){ |
|
| 84 | + if ($this->location == null) { |
|
| 85 | 85 | $this->location = $this->repository->getLocationService()->loadLocation($this->content->contentInfo->mainLocationId); |
| 86 | 86 | } |
| 87 | 87 | return $this->location; |