git.iko.soy/typeable/swagger2
on master help sign in
Add HasParamSchema instance for NamedSchema
commit5411e2e5a9708a31f5597e58dd0a5a7eb99e3962 authorNickolay Kudasov <nickolay.kudasov@gmail.com> dateMon 1 Feb 2016, 17:35 (11 years ago) parente48bd53
1 file changed+3−1
src/Data/Swagger/Lens.hs+3−1
src/Data/Swagger/Lens.hs+3−1
@@ -83,10 +83,12 @@ instance At Responses where at n = responses . at n
8383instance Ixed Operation where ix n = responses . ix n
8484instance At Operation where at n = responses . at n
8585
86+instance HasParamSchema NamedSchema (ParamSchema Schema) where paramSchema = schema.paramSchema
87+
8688-- HasType instances
8789instance HasType Header (SwaggerType Header) where type_ = paramSchema.type_
8890instance HasType Schema (SwaggerType Schema) where type_ = paramSchema.type_
89−instance HasType NamedSchema (SwaggerType Schema) where type_ = schema.paramSchema.type_
91+instance HasType NamedSchema (SwaggerType Schema) where type_ = paramSchema.type_
9092instance HasType ParamOtherSchema (SwaggerType ParamOtherSchema) where type_ = paramSchema.type_
9193
9294-- HasDefault instances