| Conditions | 3 |
| Paths | 3 |
| Total Lines | 15 |
| Code Lines | 8 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 9 |
| CRAP Score | 3 |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 40 | 1 | public function onKernelRequest(GetResponseEvent $event) |
|
| 41 | { |
||
| 42 | 1 | $request = $event->getRequest(); |
|
| 43 | |||
| 44 | 1 | $version = $request->request->get('version'); |
|
| 45 | |||
| 46 | 1 | if ($version) { |
|
| 47 | 1 | $this->version = $version; |
|
| 48 | 1 | $request->attributes->set('version', $this->version); |
|
| 49 | |||
| 50 | 1 | if ($this->viewHandler instanceof ConfigurableViewHandlerInterface) { |
|
| 51 | 1 | $this->viewHandler->setExclusionStrategyVersion($this->version); |
|
| 52 | } |
||
| 53 | } |
||
| 54 | 1 | } |
|
| 55 | } |
||
| 56 |