Skip to content
This repository was archived by the owner on Feb 7, 2024. It is now read-only.

Commit 82bba5b

Browse files
committed
Fix content length method
1 parent 15e6b6a commit 82bba5b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/HttpApi/Controllers/Controller.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ protected function findContentLength(array $headers): int
5252
{
5353
return Collection::make($headers)->first(function ($values, $header) {
5454
return strtolower($header) === 'content-length';
55-
});
55+
})[0] ?? 0;
5656
}
5757

5858
public function onMessage(ConnectionInterface $from, $msg)

0 commit comments

Comments
 (0)