@@ -115,16 +115,20 @@ def _get_parameters(link, encoding):
115115 'required' : field .required ,
116116 'in' : 'formData' ,
117117 'description' : field .description ,
118- 'type' : field .type or 'string'
118+ 'type' : field .type or 'string' ,
119119 }
120+ if field .type == 'array' :
121+ parameter ['items' ] = {'type' : 'string' }
120122 parameters .append (parameter )
121123 else :
122124 # Expand coreapi fields with location='form' into a single swagger
123125 # parameter, with a schema containing multiple properties.
124126 schema_property = {
125127 'description' : field .description ,
126- 'type' : field .type or 'string'
128+ 'type' : field .type or 'string' ,
127129 }
130+ if field .type == 'array' :
131+ schema_property ['items' ] = {'type' : 'string' }
128132 properties [field .name ] = schema_property
129133 if field .required :
130134 required .append (field .name )
@@ -148,8 +152,10 @@ def _get_parameters(link, encoding):
148152 'required' : field .required ,
149153 'in' : location ,
150154 'description' : field .description ,
151- 'type' : field .type or 'string'
155+ 'type' : field .type or 'string' ,
152156 }
157+ if field .type == 'array' :
158+ parameter ['items' ] = {'type' : 'string' }
153159 parameters .append (parameter )
154160
155161 if properties :
0 commit comments