8000 Merge pull request #152 from canvural/patch-2 · geocoder-php/GeocoderLaravel@58579e4 · GitHub
[go: up one dir, main page]

Skip to content

Commit 58579e4

Browse files
authored
Merge pull request #152 from canvural/patch-2
2 parents 2da0d71 + 65a9373 commit 58579e4

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

src/ProviderAndDumperAggregator.php

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -219,14 +219,13 @@ protected function getArguments(array $arguments, string $provider) : array
219219
}
220220

221221
$adapter = $this->getAdapterClass($provider);
222-
$reader = null;
223222

224223
if ($adapter) {
225224
if ($this->requiresReader($provider)) {
226-
$reader = config('geocoder.reader');
225+
array_unshift($arguments, new $adapter(config('geocoder.reader')));
226+
} else {
227+
array_unshift($arguments, new $adapter());
227228
}
228-
229-
array_unshift($arguments, new $adapter($reader));
230229
}
231230

232231
return $arguments;

0 commit comments

Comments
 (0)
0