mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-06-13 13:54:23 +00:00
write privacy event only if person is available #3
This commit is contained in:
parent
73ef9e1f8e
commit
9024f0cfca
@ -540,11 +540,13 @@ class SingleTaskController extends Controller
|
|||||||
|
|
||||||
$form->handleRequest($request);
|
$form->handleRequest($request);
|
||||||
|
|
||||||
$event = new PrivacyEvent($person, array(
|
if (isset($person)) {
|
||||||
'element_class' => SingleTask::class,
|
$event = new PrivacyEvent($person, array(
|
||||||
'action' => 'list'
|
'element_class' => SingleTask::class,
|
||||||
));
|
'action' => 'list'
|
||||||
$this->eventDispatcher->dispatch(PrivacyEvent::PERSON_PRIVACY_EVENT, $event);
|
));
|
||||||
|
$this->eventDispatcher->dispatch(PrivacyEvent::PERSON_PRIVACY_EVENT, $event);
|
||||||
|
}
|
||||||
|
|
||||||
return $this->render('ChillTaskBundle:SingleTask:index.html.twig',
|
return $this->render('ChillTaskBundle:SingleTask:index.html.twig',
|
||||||
\array_merge($viewParams, [ 'form' => $form->createView() ]));
|
\array_merge($viewParams, [ 'form' => $form->createView() ]));
|
||||||
|
Loading…
x
Reference in New Issue
Block a user