mirror of
https://github.com/openvk/openvk
synced 2024-11-13 10:39:24 +03:00
Support: Check ticket for existence before showing
This commit is contained in:
parent
bdf97e4286
commit
763c0c91e2
1 changed files with 4 additions and 0 deletions
|
@ -169,6 +169,10 @@ final class SupportPresenter extends OpenVKPresenter
|
|||
{
|
||||
$this->assertPermission('openvk\Web\Models\Entities\TicketReply', 'write', 0);
|
||||
$ticket = $this->tickets->get($id);
|
||||
|
||||
if(!$ticket || $ticket->isDeleted() != 0)
|
||||
$this->notFound();
|
||||
|
||||
$ticketComments = $this->comments->getCommentsById($id);
|
||||
$this->template->ticket = $ticket;
|
||||
$this->template->comments = $ticketComments;
|
||||
|
|
Loading…
Reference in a new issue