Conditions | 3 |
Paths | 3 |
Total Lines | 16 |
Code Lines | 11 |
Lines | 0 |
Ratio | 0 % |
Tests | 0 |
CRAP Score | 12 |
Changes | 0 |
1 | <?php |
||
23 | public function handle(): void |
||
24 | { |
||
25 | if ($this->conversable instanceof Intent) { |
||
26 | $session = session(); |
||
27 | $session->setIntent($this->conversable); |
||
28 | $session->setInteraction(null); |
||
29 | |||
30 | kernel()->setSession($session); |
||
31 | |||
32 | $this->conversable->handle($this->message); |
||
33 | } elseif ($this->conversable instanceof Interaction) { |
||
34 | $this->conversable->handle($this->message); |
||
35 | } else { |
||
36 | $this->conversable->handle($this->message); |
||
37 | } |
||
38 | } |
||
39 | } |
||
40 |