8000 [TwigBridge] Deprecate passing `$field` argument to `is_granted()` by smnandre · Pull Request #59282 · symfony/symfony · GitHub
[go: up one dir, main page]

Skip to content

[TwigBridge] Deprecate passing $field argument to is_granted() #59282

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 6 commits into from
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
update deprecation message
  • Loading branch information
smnandre committed Dec 22, 2024
commit db58918539adcca4c66fb4cb61d877b800c18a6f
2 changes: 1 addition & 1 deletion src/Symfony/Bridge/Twig/Extension/SecurityExtension.php
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ public function isGranted(mixed $role, mixed $object = null, ?string $field = nu
}

if (null !== $field) {
trigger_deprecation('symfony/twig-bridge', '7.3', 'Passing a "field" argument to the "is_granted" Twig function is deprecated. It will be removed in version 8.0.');
trigger_deprecation('symfony/twig-bridge', '7.3', 'Passing the "$field" argument to the "is_granted" Twig function is deprecated and will be removed in version 8.0.');

$object = new FieldVote($object, $field);
}
Expand Down
Loading
0