Conditions | 2 |
Paths | 3 |
Total Lines | 10 |
Code Lines | 6 |
Lines | 0 |
Ratio | 0 % |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
31 | public function __invoke(string $uuid): Response |
||
32 | { |
||
33 | try { |
||
34 | $this->commandBus->dispatch(new DeleteUser($uuid)); |
||
35 | $this->addFlash('success', 'User deleted started!'); |
||
36 | } catch (\RuntimeException $exception) { |
||
37 | $this->addFlash('error', $exception->getMessage()); |
||
38 | } |
||
39 | |||
40 | return new RedirectResponse($this->generateUrl('admin_user_index')); |
||
41 | } |
||
43 |