Fixed everyone could delete posts
This commit is contained in:
parent
736c0a66ff
commit
40197d6c39
1 changed files with 1 additions and 0 deletions
|
@ -145,6 +145,7 @@ final class PostController extends AbstractController
|
||||||
|
|
||||||
public function deletePost($postNameOrId)
|
public function deletePost($postNameOrId)
|
||||||
{
|
{
|
||||||
|
$this->privilegeService->assertPrivilege(Privilege::DELETE_POSTS);
|
||||||
$post = $this->postService->getByNameOrId($postNameOrId);
|
$post = $this->postService->getByNameOrId($postNameOrId);
|
||||||
$this->postService->deletePost($post);
|
$this->postService->deletePost($post);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue