Mercurial > public > src > rhodecode
diff pylons_app/controllers/error.py @ 260:6ada8c223374
made global funcion to clean repo names, and remove all special chars from the name.
Switched message slug into webhelpers function
author | Marcin Kuzminski <marcin@python-works.com> |
---|---|
date | Sun, 06 Jun 2010 21:54:54 +0200 |
parents | 70f645fa97cc |
children | 9a70fe918a81 |
line wrap: on
line diff
--- a/pylons_app/controllers/error.py Sun Jun 06 10:57:49 2010 +0200 +++ b/pylons_app/controllers/error.py Sun Jun 06 21:54:54 2010 +0200 @@ -8,7 +8,7 @@ from pylons_app.lib.base import BaseController, render from pylons.middleware import media_path from pylons_app.lib.utils import check_repo -from pylons_app.lib.filters import clean_repo +import pylons_app.lib.helpers as h log = logging.getLogger(__name__) class ErrorController(BaseController): @@ -39,7 +39,7 @@ if resp.status_int == 404: org_e = request.environ.get('pylons.original_request').environ c.repo_name = repo_name = org_e['PATH_INFO'].split('/')[1] - c.repo_name_cleaned = clean_repo(c.repo_name) + c.repo_name_cleaned = h.repo_name_slug(c.repo_name) if check_repo(repo_name, g.base_path): return render('/errors/error_404.html')