Merge pull request #1208 from nelmio/GuilhemN-patch-1

Add a missing variable initialisation
This commit is contained in:
Guilhem N 2018-01-26 12:49:41 +01:00 committed by GitHub
commit 819cbe354f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -27,6 +27,7 @@ trait RouteDescriberTrait
*/
private function getOperations(Swagger $api, Route $route): array
{
$operations = [];
$path = $api->getPaths()->get($this->normalizePath($route->getPath()));
$methods = $route->getMethods() ?: Swagger::$METHODS;
foreach ($methods as $method) {