misc: make sure redirect URLs are real strings
gitea-wip/wcs/pipeline/head Build started... Details
gitea/wcs/pipeline/head Build started... Details

This commit is contained in:
Frédéric Péters 2020-04-01 16:08:56 +02:00
parent 2e54d9ce00
commit 896da2d087
1 changed files with 5 additions and 0 deletions

View File

@ -83,6 +83,11 @@ def perform_items(items, formdata, depth=20):
# performs the items of the new status
wf_status = formdata.get_status()
url = perform_items(wf_status.items, formdata, depth=depth-1) or url
if url:
# hack around webtest as it checks type(url) is str and
# this won't work on django safe strings (isinstance would work);
# adding '' makes sure we get a "real" str object.
url = url + ''
return url