Browse files

2867 Fixes a problem with passing unicode to url_for

Forces the file_url to be ascii as it appears that for some reason, and only
occassionally OFS returns unicode instead of str.  We don't want to fix OFS
as it is scheduled for removal and we can fix routes as it is already out of
  • Loading branch information...
1 parent 18f95bf commit c73b6f00c16f526015a903642618806a4c642d72 @rossjones rossjones committed Aug 16, 2012
Showing with 1 addition and 1 deletion.
  1. +1 −1 ckan/controllers/
@@ -187,7 +187,7 @@ def file(self, label):
fapp = FileApp(filepath, headers=None, **headers)
return fapp(request.environ, self.start_response)
- h.redirect_to(file_url)
+ h.redirect_to(file_url.encode('ascii','ignore'))
class StorageAPIController(BaseController):

0 comments on commit c73b6f0

Please sign in to comment.