@@ -154,12 +154,12 @@ |
||
154 | 154 | |
155 | 155 | // If extensions are set, filter other files out |
156 | 156 | if ($item->extensions) { |
157 | - $files = array_filter($files, function ($file) use ($item) { |
|
157 | + $files = array_filter($files, function($file) use ($item) { |
|
158 | 158 | return in_array($file['extension'], $item->extensions); |
159 | 159 | }); |
160 | 160 | } |
161 | 161 | |
162 | - return array_map(function ($file) use ($dir) { |
|
162 | + return array_map(function($file) use ($dir) { |
|
163 | 163 | return $dir . DIRECTORY_SEPARATOR . $file['path']; |
164 | 164 | }, $files); |
165 | 165 | } |
@@ -30,7 +30,7 @@ discard block |
||
30 | 30 | public function saveTranslations(Translations $translations) |
31 | 31 | { |
32 | 32 | $locale = $translations->getLanguage(); |
33 | - $domain = (string)$translations->getDomain(); |
|
33 | + $domain = (string) $translations->getDomain(); |
|
34 | 34 | |
35 | 35 | if (!$locale) { |
36 | 36 | throw new InvalidTranslationException('Locale is missing'); |
@@ -136,7 +136,7 @@ discard block |
||
136 | 136 | $item->key = $this->getKey($locale, $domain, $translation); |
137 | 137 | $item->domain = $domain; |
138 | 138 | $item->locale = $locale; |
139 | - $item->context = (string)$translation->getContext(); |
|
139 | + $item->context = (string) $translation->getContext(); |
|
140 | 140 | $item->original = $translation->getOriginal(); |
141 | 141 | $item->translation = $translation->getTranslation(); |
142 | 142 | $item->originalPlural = $translation->getPlural(); |
@@ -160,8 +160,8 @@ discard block |
||
160 | 160 | { |
161 | 161 | return $this->convertItems( |
162 | 162 | $locale, |
163 | - (string)$domain, |
|
164 | - $this->repository->getAll($locale, (string)$domain) |
|
163 | + (string) $domain, |
|
164 | + $this->repository->getAll($locale, (string) $domain) |
|
165 | 165 | ); |
166 | 166 | } |
167 | 167 | |
@@ -176,8 +176,8 @@ discard block |
||
176 | 176 | { |
177 | 177 | return $this->convertItems( |
178 | 178 | $locale, |
179 | - (string)$domain, |
|
180 | - $this->repository->getEnabled($locale, (string)$domain) |
|
179 | + (string) $domain, |
|
180 | + $this->repository->getEnabled($locale, (string) $domain) |
|
181 | 181 | ); |
182 | 182 | } |
183 | 183 | |
@@ -192,8 +192,8 @@ discard block |
||
192 | 192 | { |
193 | 193 | return $this->convertItems( |
194 | 194 | $locale, |
195 | - (string)$domain, |
|
196 | - $this->repository->getEnabledTranslated($locale, (string)$domain) |
|
195 | + (string) $domain, |
|
196 | + $this->repository->getEnabledTranslated($locale, (string) $domain) |
|
197 | 197 | ); |
198 | 198 | } |
199 | 199 | |
@@ -208,8 +208,8 @@ discard block |
||
208 | 208 | { |
209 | 209 | return $this->convertItems( |
210 | 210 | $locale, |
211 | - (string)$domain, |
|
212 | - $this->repository->getRequiresTranslating($locale, (string)$domain) |
|
211 | + (string) $domain, |
|
212 | + $this->repository->getRequiresTranslating($locale, (string) $domain) |
|
213 | 213 | ); |
214 | 214 | } |
215 | 215 | |
@@ -223,7 +223,7 @@ discard block |
||
223 | 223 | */ |
224 | 224 | private function convertItems(string $locale, $domain, array $items): Translations |
225 | 225 | { |
226 | - $domain = (string)$domain; |
|
226 | + $domain = (string) $domain; |
|
227 | 227 | |
228 | 228 | $translations = new Translations; |
229 | 229 | $translations->setDomain($domain); |