| Conditions | 3 |
| Paths | 3 |
| Total Lines | 13 |
| Code Lines | 6 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 1 | ||
| Bugs | 1 | Features | 0 |
| 1 | <?php |
||
| 10 | public function handle($request, Closure $next) |
||
| 11 | { |
||
| 12 | $signature = $request->header('X-Multicoin-Signature'); |
||
| 13 | |||
| 14 | if (! $signature) { |
||
| 15 | throw WebhookFailed::missingSignature(); |
||
| 16 | } |
||
| 17 | |||
| 18 | if (! $this->isValid($signature, $request)) { |
||
| 19 | throw WebhookFailed::invalidSignature($signature); |
||
| 20 | } |
||
| 21 | |||
| 22 | return $next($request); |
||
| 23 | } |
||
| 39 |