Skip to content

Commit

Permalink
Fix compatibility of w/ php 8.1
Browse files Browse the repository at this point in the history
jsonSerialize has to have explicit return type in php 8.1 which is
compatible with mixed.
  • Loading branch information
jost125 committed Jan 6, 2022
1 parent 87d2ded commit b10be92
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/Bonami/Collection/Enum.php
Original file line number Diff line number Diff line change
Expand Up @@ -148,8 +148,7 @@ public function hashCode()
return $this->getValue();
}

/** @return mixed */
public function jsonSerialize()
public function jsonSerialize(): string
{
return (string)$this->value;
}
Expand Down

0 comments on commit b10be92

Please sign in to comment.