Merged in hotfix/MAPG-166-response-to-head-requests (pull request #136)

MAPG-166 response to HEAD request with the GET content
This commit is contained in:
Bence Pőcze 2020-06-23 13:27:48 +00:00
commit dc1aedd28f

View File

@ -45,6 +45,11 @@ class RouteCollection
{ {
$groupNumber = count($uri); $groupNumber = count($uri);
// response to HEAD request with the GET content
if ($method === 'head') {
$method = 'get';
}
if (!isset($this->searchTable[$method][$groupNumber])) { if (!isset($this->searchTable[$method][$groupNumber])) {
return null; return null;
} }