Skip to content

Commit a37126d

Browse files
alexissavinziirish
authored andcommitted
fix: properly set pattern in reqparse object list when using option
"append"
1 parent 401d087 commit a37126d

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

flask_restx/reqparse.py

+2
Original file line numberDiff line numberDiff line change
@@ -300,6 +300,8 @@ def __schema__(self):
300300
)
301301
if self.action == "append":
302302
param["items"] = {"type": param["type"]}
303+
if "pattern" in param:
304+
param["items"]["pattern"] = param.pop("pattern")
303305
param["type"] = "array"
304306
param["collectionFormat"] = "multi"
305307
if self.action == "split":

0 commit comments

Comments
 (0)