| Conditions | 2 |
| Paths | 2 |
| Total Lines | 15 |
| Code Lines | 8 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 27 | public function handle(Command $command): Response |
||
| 28 | { |
||
| 29 | try { |
||
| 30 | $this->client->run( |
||
| 31 | 'CREATE (n:{node}) SET n += {data}', |
||
| 32 | [ |
||
| 33 | 'node' => $command->getNodeName(), |
||
| 34 | 'data' => $command->getData(), |
||
| 35 | ] |
||
| 36 | ); |
||
| 37 | } catch (Neo4jExceptionInterface $e) { |
||
| 38 | return Response::fail($e->getMessage()); |
||
| 39 | } |
||
| 40 | |||
| 41 | return Response::ok(); |
||
| 42 | } |
||
| 44 |