Add float validator case to spec to prevent fallthrough
This commit is contained in:
parent
2b82148591
commit
30a14f01e8
3 changed files with 6 additions and 2 deletions
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
|
@ -319,6 +319,10 @@ class Swagger2 extends Format
|
||||||
$node['type'] = $validator->getType();
|
$node['type'] = $validator->getType();
|
||||||
$node['format'] = 'int32';
|
$node['format'] = 'int32';
|
||||||
break;
|
break;
|
||||||
|
case 'Utopia\Validator\FloatValidator':
|
||||||
|
$node['type'] = 'number';
|
||||||
|
$node['format'] = 'float';
|
||||||
|
break;
|
||||||
case 'Utopia\Validator\Length':
|
case 'Utopia\Validator\Length':
|
||||||
$node['type'] = $validator->getType();
|
$node['type'] = $validator->getType();
|
||||||
break;
|
break;
|
||||||
|
|
Loading…
Reference in a new issue