@@ -115,16 +115,20 @@ def _get_parameters(link, encoding):
115
115
'required' : field .required ,
116
116
'in' : 'formData' ,
117
117
'description' : field .description ,
118
- 'type' : field .type or 'string'
118
+ 'type' : field .type or 'string' ,
119
119
}
120
+ if field .type == 'array' :
121
+ parameter ['items' ] = {'type' : 'string' }
120
122
parameters .append (parameter )
121
123
else :
122
124
# Expand coreapi fields with location='form' into a single swagger
123
125
# parameter, with a schema containing multiple properties.
124
126
schema_property = {
125
127
'description' : field .description ,
126
- 'type' : field .type or 'string'
128
+ 'type' : field .type or 'string' ,
127
129
}
130
+ if field .type == 'array' :
131
+ schema_property ['items' ] = {'type' : 'string' }
128
132
properties [field .name ] = schema_property
129
133
if field .required :
130
134
required .append (field .name )
@@ -148,8 +152,10 @@ def _get_parameters(link, encoding):
148
152
'required' : field .required ,
149
153
'in' : location ,
150
154
'description' : field .description ,
151
- 'type' : field .type or 'string'
155
+ 'type' : field .type or 'string' ,
152
156
}
157
+ if field .type == 'array' :
158
+ parameter ['items' ] = {'type' : 'string' }
153
159
parameters .append (parameter )
154
160
155
161
if properties :
0 commit comments