| Conditions | 8 |
| Paths | 21 |
| Total Lines | 20 |
| Code Lines | 12 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 37 | public function handle(EntityChange $event) |
||
| 38 | { |
||
| 39 | // phpcs:disable Generic.CodeAnalysis.EmptyStatement.DetectedCatch |
||
| 40 | switch ($event->getEntityName()) { |
||
| 41 | case AdminResource::class: |
||
| 42 | case User::class: |
||
| 43 | case UserGroup::class: |
||
| 44 | try { |
||
| 45 | $this->cacheManager->clearAll(); |
||
| 46 | } catch (\Exception $e) { |
||
| 47 | // Empty catch |
||
| 48 | } |
||
| 49 | |||
| 50 | break; |
||
| 51 | } |
||
| 52 | |||
| 53 | if ($event->getEntityName() == User::class && $event->getEntityId() == $this->session->get(Session::USER_ID)) { |
||
| 54 | try { |
||
| 55 | $this->session->flush(); |
||
| 56 | } catch (\Exception $e) { |
||
| 57 | // Empty catch |
||
| 63 |