mirror of
https://github.com/correl/openapi-core.git
synced 2025-01-04 03:00:15 +00:00
Merge pull request #112 from diogobaeder/master
Properly formatting UUID if value to be unmarshalled is already a UUID.
This commit is contained in:
commit
c846b2e453
3 changed files with 26 additions and 1 deletions
|
@ -20,6 +20,7 @@ from openapi_core.schema.schemas.exceptions import (
|
|||
)
|
||||
from openapi_core.schema.schemas.util import (
|
||||
forcebool, format_date, format_datetime,
|
||||
format_uuid,
|
||||
)
|
||||
from openapi_core.schema.schemas.validators import (
|
||||
TypeValidator, AttributeValidator,
|
||||
|
@ -46,7 +47,7 @@ class Schema(object):
|
|||
format_date, TypeValidator(date, exclude=datetime)),
|
||||
SchemaFormat.DATETIME: Format(format_datetime, TypeValidator(datetime)),
|
||||
SchemaFormat.BINARY: Format(binary_type, TypeValidator(binary_type)),
|
||||
SchemaFormat.UUID: Format(UUID, TypeValidator(UUID)),
|
||||