mirror of
https://github.com/ilyakooo0/deriving-openapi3.git
synced 2024-09-11 10:25:55 +03:00
Merge pull request #4 from aleator/ville/add-some-cpp
Adde cpp for RejectUnknownFields
This commit is contained in:
commit
90e0d3298d
@ -98,8 +98,10 @@ instance OpenApiOptionModifier UnwrapUnaryRecords where
|
||||
|
||||
instance OpenApiOptionModifier OmitNothingFields
|
||||
|
||||
#if MIN_VERSION_deriving_aeson(0,2,4)
|
||||
instance OpenApiOptionModifier RejectUnknownFields where
|
||||
openApiSchemaModifier = schema . additionalProperties .~ Just (AdditionalPropertiesAllowed False)
|
||||
#endif
|
||||
|
||||
instance StringModifier f => OpenApiOptionModifier (FieldLabelModifier f) where
|
||||
openApiOptionsModifier o = o {fieldLabelModifier = getStringModifier @f}
|
||||
|
Loading…
Reference in New Issue
Block a user