Skip to content

Commit 9c700ac

Browse files
committed
minor #878 Fixed exemple in alternative use of isGranted annotation (mickaelandrieu)
This PR was merged into the master branch. Discussion ---------- Fixed exemple in alternative use of isGranted annotation Not really important, but replacing one but the alternative don't produce the same result 👍 Commits ------- d97a17c Fixed exemple in alternative use of isGranted annotation
2 parents 6a4ce6b + d97a17c commit 9c700ac

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Controller/Admin/BlogController.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,7 @@ public function new(Request $request): Response
118118
public function show(Post $post): Response
119119
{
120120
// This security check can also be performed
121-
// using an annotation: @IsGranted("show", subject="post")
121+
// using an annotation: @IsGranted("show", subject="post", message="Posts can only be shown to their authors.")
122122
$this->denyAccessUnlessGranted('show', $post, 'Posts can only be shown to their authors.');
123123

124124
return $this->render('admin/blog/show.html.twig', [

0 commit comments

Comments
 (0)