Skip to content

Commit

Permalink
Update Point.php
Browse files Browse the repository at this point in the history
Right now this lib throws:

> Return type of Grimzy\LaravelMysqlSpatial\Types\Point::jsonSerialize() should either be compatible with JsonSerializable::jsonSerialize(): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in xxx/vendor/grimzy/laravel-mysql-spatial/src/Types/Point.php on line 95

Fixes grimzy#182
  • Loading branch information
Livijn authored Nov 8, 2022
1 parent 2ca9f2f commit 7eba42a
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/Types/Point.php
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,7 @@ public static function fromJson($geoJson)
*
* @return \GeoJson\Geometry\Point
*/
#[\ReturnTypeWillChange]
public function jsonSerialize()
{
return new GeoJsonPoint([$this->getLng(), $this->getLat()]);
Expand Down

0 comments on commit 7eba42a

Please sign in to comment.