Skip to content

Commit

Permalink
Use named parameter for json_decode()
Browse files Browse the repository at this point in the history
  • Loading branch information
BenMorel committed Feb 22, 2023
1 parent 8649a9c commit d4ffe92
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/IO/GeoJSONReader.php
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ public function __construct(bool $lenient = false)
public function read(string $geoJson): Geometry|Feature|FeatureCollection
{
try {
$geoJsonObject = json_decode($geoJson, false, 512, JSON_THROW_ON_ERROR);
$geoJsonObject = json_decode($geoJson, flags: JSON_THROW_ON_ERROR);
} catch (JsonException $e) {
throw GeometryIOException::invalidGeoJSON('Unable to parse GeoJSON string.', $e);
}
Expand Down

0 comments on commit d4ffe92

Please sign in to comment.