Skip to content

Commit

Permalink
Fixed the url_for_* helpers when both SCRIPT_NAME and ckan.root_path …
Browse files Browse the repository at this point in the history
…are defined
  • Loading branch information
LaurentGoderre authored and wardi committed May 25, 2016
1 parent 6148c25 commit f33a3d7
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions ckan/lib/base.py
Expand Up @@ -247,6 +247,10 @@ def __before__(self, action, **params):
'new_activities',
'Use `h.new_activities` instead.')

# Prevents the variable interfering with the root_path logic
if 'SCRIPT_NAME' in request.environ:
request.environ['SCRIPT_NAME'] = ''

def _identify_user(self):
'''Try to identify the user
If the user is identified then:
Expand Down

0 comments on commit f33a3d7

Please sign in to comment.