changeset 733:5b2029e9fc58

allow '-' in usernames (backport to 1.5)
author Thomas Waldmann <tw AT waldmann-edv DOT de>
date Wed, 31 May 2006 12:04:43 +0200
parents 43b158d3cf22
children bf2435e61f97
files MoinMoin/__init__.py MoinMoin/user.py docs/CHANGES
diffstat 3 files changed, 5 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/MoinMoin/__init__.py	Sun May 28 01:54:35 2006 +0200
+++ b/MoinMoin/__init__.py	Wed May 31 12:04:43 2006 +0200
@@ -1,6 +1,6 @@
 # -*- coding: iso-8859-1 -*-
 """
-MoinMoin Version 1.6.0alpha 8e8130a1f46b+ tip
+MoinMoin Version 1.6.0alpha 43b158d3cf22+ tip
 
 @copyright: 2000-2006 by Jürgen Hermann <jh@web.de>
 @license: GNU GPL, see COPYING for details.
--- a/MoinMoin/user.py	Sun May 28 01:54:35 2006 +0200
+++ b/MoinMoin/user.py	Wed May 31 12:04:43 2006 +0200
@@ -137,8 +137,8 @@
     @return: user name that can be used in acl lines
     """
     name = name.replace('_', ' ') # we treat _ as a blank
-    username_allowedchars = "'@." # ' for names like O'Brian or email addresses.
-                                  # "," and ":" must not be allowed (ACL delimiters).
+    username_allowedchars = "'@.-" # ' for names like O'Brian or email addresses.
+                                   # "," and ":" must not be allowed (ACL delimiters).
     # Strip non alpha numeric characters (except username_allowedchars), keep white space
     name = ''.join([c for c in name if c.isalnum() or c.isspace() or c in username_allowedchars])
 
--- a/docs/CHANGES	Sun May 28 01:54:35 2006 +0200
+++ b/docs/CHANGES	Wed May 31 12:04:43 2006 +0200
@@ -84,6 +84,8 @@
     * fix deletion of empty Interwiki links ([wiki:MoinMaster: mm entry page])
     * fix mod_python attachment upload bug (thanks to Nick Phillips)
     * fix show_version to show it in the same way as SystemInfo
+    * allow "-" in usernames (fixes "Invalid user name" msg)
+
 
 Version 1.5.current:
   Developer notes: