Unified code style nullable description parameter

We define unified parameter types for validating a request reference,
such as 'boolean', 'url' and 'description'. In order to keep the code
style consistent, each schema should use it in addition to its own
specific parameters.

For catalog schema, parameter 'description' in _region_properties and
_endpoint_group_properties has different definitions, which reduces the
readability of the code.

Change-Id: Ia94bc3368f3623a91ffde9a78d2310f8a8e290c2
This commit is contained in:
zlyqqq 2018-08-01 16:30:36 +08:00
parent ac569a88fb
commit 91b4009094
1 changed files with 1 additions and 3 deletions

View File

@ -20,9 +20,7 @@ _service_properties_type = {
}
_region_properties = {
'description': {
'type': ['string', 'null'],
},
'description': validation.nullable(parameter_types.description),
# NOTE(lbragstad): Regions use ID differently. The user can specify the ID
# or it will be generated automatically.
'id': {