Skip to content

Commit

Permalink
#201 Revert method signature change to avoid BC breaks
Browse files Browse the repository at this point in the history
  • Loading branch information
scrummer committed Aug 30, 2024
1 parent a0ef56a commit 8c208eb
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/CoreExtension/Provider/RoleOptionsProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ public function __construct(array $systemRoles)

public function getOptions(array $context, Data $fieldDefinition): array
{
$roles = [$this->getDefaultValue()];
$roles = [$this->getDefaultValue($context, $fieldDefinition)];

foreach ($this->originalRoles as $originalRole => $inheritedRoles) {
array_push($roles, $originalRole, ...$inheritedRoles);
Expand All @@ -36,7 +36,7 @@ public function hasStaticOptions(array $context, Data $fieldDefinition): bool
return false;
}

public function getDefaultValue(): string
public function getDefaultValue(array $context, Data $fieldDefinition): ?string
{
return 'ROLE_USER';
}
Expand Down

0 comments on commit 8c208eb

Please sign in to comment.