Conditions | 3 |
Paths | 3 |
Total Lines | 13 |
Code Lines | 7 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
21 | public function handleEventFromRequest(Request $request): ?string |
||
22 | { |
||
23 | foreach (EventConstant::WEBHOOK_EVENT_HEADER as $platform => $header) { |
||
24 | $event = $request->server->get($header); |
||
25 | if (!is_null($event)) { |
||
26 | $this->event->platform = $platform; |
||
27 | $this->setPlatFormForEvent($platform); |
||
28 | |||
29 | return $event; |
||
30 | } |
||
31 | } |
||
32 | |||
33 | return null; |
||
34 | } |
||
46 |