Skip to content

Commit

Permalink
fix issue
Browse files Browse the repository at this point in the history
  • Loading branch information
mission-liao committed Apr 9, 2017
1 parent 9d22208 commit 2d86d0f
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion pyswagger/contrib/client/webapp2.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,9 +45,15 @@ def request(self, req_and_resp, opt={}):
req.prepare(scheme=self.prepare_schemes(req), handle_files=True)
req._patch(opt)

url = req.url
if req.query:
if url[-1] not in ('?', '&'):
url += '&' if ('?' in url) else '?'
url += six.moves.urllib.parse.urlencode(req.query)

# initiate an request every time
_req = webapp2.Request.blank(
req.url,
url,
headers=req.header.items(),
POST=req.data,
**self.__kw
Expand Down

0 comments on commit 2d86d0f

Please sign in to comment.