mirror of
https://github.com/retailcrm/NelmioApiDocBundle.git
synced 2025-02-02 23:59:26 +03:00
Required for PathVarriables is no longer overwritten, if already set. Type is no longer overwritten if already set
This commit is contained in:
parent
7690f6cfb5
commit
35f83640d6
@ -33,8 +33,12 @@ final class RouteMetadataDescriber implements RouteDescriberInterface
|
||||
}
|
||||
|
||||
$parameter = $operation->getParameters()->get($pathVariable, 'path');
|
||||
$parameter->setRequired(true);
|
||||
$parameter->setType('string');
|
||||
if (null === $parameter->getRequired()) {
|
||||
$parameter->setRequired(true);
|
||||
}
|
||||
if(null === $parameter->getType()) {
|
||||
$parameter->setType('string');
|
||||
}
|
||||
|
||||
if (isset($requirements[$pathVariable])) {
|
||||
$parameter->setFormat($requirements[$pathVariable]);
|
||||
|
Loading…
x
Reference in New Issue
Block a user