Skip to content

Commit

Permalink
Minor clean-up
Browse files Browse the repository at this point in the history
git-svn-id: svn://cherokee-project.com/cherokee/trunk@6377 5dc97367-97f1-0310-9951-d761b3857238
  • Loading branch information
alobbs committed Mar 8, 2011
1 parent 60fe8f2 commit 17005c4
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions admin/validations.py
Expand Up @@ -210,9 +210,10 @@ def can_create_file (value, nochroot=False):


def is_safe_id (value): def is_safe_id (value):
for v in value: for v in value:
if v not in string.letters + string.digits and \ if v not in string.letters and \
v not in string.digits and \
v not in "_-.": v not in "_-.":
raise ValueError, _('Invalid char. Accepts: letters, digits, _, - and .') raise ValueError, _('Invalid char. Accepts: letters, digits, _, - and .')
return value return value


def is_safe_id_list (value): def is_safe_id_list (value):
Expand Down

0 comments on commit 17005c4

Please sign in to comment.