Skip to content

Commit

Permalink
Fix type hint on OrderBy attribute
Browse files Browse the repository at this point in the history
PHPStan 2.0 does not accept a string backed enum as a string.
  • Loading branch information
curry684 authored Jan 6, 2025
1 parent 68c8774 commit a7c35dc
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/Mapping/OrderBy.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,12 @@
namespace Doctrine\ORM\Mapping;

use Attribute;
use Doctrine\Common\Collections\Order;

#[Attribute(Attribute::TARGET_PROPERTY)]
final class OrderBy implements MappingAttribute
{
/** @param array<string> $value */
/** @param array<string, string|Order> $value */
public function __construct(
public readonly array $value,
) {
Expand Down

0 comments on commit a7c35dc

Please sign in to comment.