@@ -199,7 +199,7 @@ |
||
| 199 | 199 | * |
| 200 | 200 | * @param array|string|null $link |
| 201 | 201 | * @param mixed $query |
| 202 | - * @param mixed $field |
|
| 202 | + * @param string $field |
|
| 203 | 203 | * @return \Distilleries\Contentful\Models\Base\ContentfulModel|null |
| 204 | 204 | */ |
| 205 | 205 | protected function contentfulEntry($link, $query = null, $field = null): ?ContentfulModel |
@@ -133,7 +133,7 @@ discard block |
||
| 133 | 133 | if (is_array($value)) { |
| 134 | 134 | if ($this->isLink($value)) { |
| 135 | 135 | try { |
| 136 | - $relationships[] = $this->relationshipSignature($value,$field); |
|
| 136 | + $relationships[] = $this->relationshipSignature($value, $field); |
|
| 137 | 137 | } catch (Exception $e) { |
| 138 | 138 | // |
| 139 | 139 | } |
@@ -141,7 +141,7 @@ discard block |
||
| 141 | 141 | foreach ($value as $entry) { |
| 142 | 142 | if ($this->isLink($entry)) { |
| 143 | 143 | try { |
| 144 | - $relationships[] = $this->relationshipSignature($entry,$field); |
|
| 144 | + $relationships[] = $this->relationshipSignature($entry, $field); |
|
| 145 | 145 | } catch (Exception $e) { |
| 146 | 146 | // |
| 147 | 147 | } |
@@ -161,7 +161,7 @@ discard block |
||
| 161 | 161 | * @return array|null |
| 162 | 162 | * @throws \Exception |
| 163 | 163 | */ |
| 164 | - private function relationshipSignature(array $localeField,string $field=''): ?array |
|
| 164 | + private function relationshipSignature(array $localeField, string $field = ''): ?array |
|
| 165 | 165 | { |
| 166 | 166 | if ($localeField['sys']['linkType'] === 'Asset') { |
| 167 | 167 | return [ |
@@ -179,7 +179,7 @@ discard block |
||
| 179 | 179 | } |
| 180 | 180 | } |
| 181 | 181 | |
| 182 | - throw new Exception('Invalid field signature... ' . PHP_EOL . print_r($localeField, true)); |
|
| 182 | + throw new Exception('Invalid field signature... '.PHP_EOL.print_r($localeField, true)); |
|
| 183 | 183 | } |
| 184 | 184 | |
| 185 | 185 | /** |
@@ -221,7 +221,7 @@ discard block |
||
| 221 | 221 | return $entry['sys']['contentType']['sys']['id']; |
| 222 | 222 | } |
| 223 | 223 | } catch (Exception $e) { |
| 224 | - throw new Exception('Unknown content-type from synced entry: ' . $contentfulId); |
|
| 224 | + throw new Exception('Unknown content-type from synced entry: '.$contentfulId); |
|
| 225 | 225 | } |
| 226 | 226 | } |
| 227 | 227 | |