~adiroiban/twisted/5441

Viewing all changes in revision 16078.

  • Committer: exarkun
  • Date: 2011-12-22 15:09:54 UTC
  • Revision ID: svn-v4:bbbe8e31-12d6-0310-92fd-ac37d47ddeeb:trunk:33400
Reject unicode locations early in twisted.web.util.redirectTo

Author: moijes12
Reviewer: exarkun
Fixes: #5236

Raise `TypeError` from `redirectTo` if the supplied URL is `unicode` instead of
`str`.  This replaces the old behavior of returning a `unicode` string in this
case which would later cause a 500 response when lower-level parts of Twisted Web
rejected the non-`str` response body string.

expand all expand all

Show diffs side-by-side

added added

removed removed

Lines of Context: