| Conditions | 3 |
| Paths | 3 |
| Total Lines | 12 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 39 | private function runImport(Request $request) |
||
| 40 | { |
||
| 41 | if ($this->token) { |
||
| 42 | $token = $request->get('token'); |
||
| 43 | if ($this->token !== $token) { |
||
| 44 | throw new RuntimeException('Token validation failed'); |
||
| 45 | } |
||
| 46 | } |
||
| 47 | |||
| 48 | $data = json_decode($request->getBody(), true); |
||
| 49 | $this->saver->save($data); |
||
| 50 | } |
||
| 51 | } |
||
| 52 |
Methods can only be called on objects. This check looks for methods being called on variables that have been inferred to never be objects.