]> git.openstreetmap.org Git - osqa.git/commitdiff
fixed an error inside of the TagNamesField method
authorqw3rty <qw3rty@0cfe37f9-358a-4d5e-be75-b63607b5c754>
Tue, 15 Jun 2010 17:52:45 +0000 (17:52 +0000)
committerqw3rty <qw3rty@0cfe37f9-358a-4d5e-be75-b63607b5c754>
Tue, 15 Jun 2010 17:52:45 +0000 (17:52 +0000)
git-svn-id: http://svn.osqa.net/svnroot/osqa/trunk@424 0cfe37f9-358a-4d5e-be75-b63607b5c754

forum/forms/qanda.py

index f38a382f3c1e675d37715873a70a873188b6ffb5..a3c093c586f4556c904ab8ae4a805c02430bfcdb 100644 (file)
@@ -87,7 +87,7 @@ class TagNamesField(forms.CharField):
 
         list_temp = []
         tagname_re = re.compile(r'^[\w+\.-]+$', re.UNICODE)
-        for key,tag in list:
+        for key,tag in list.items():
             if len(tag) > settings.FORM_MAX_LENGTH_OF_TAG or len(tag) < settings.FORM_MIN_LENGTH_OF_TAG:
                 raise forms.ValidationError(_('please use between %(min)s and %(max)s characters in you tags') % { 'min': settings.FORM_MIN_LENGTH_OF_TAG, 'max': settings.FORM_MAX_LENGTH_OF_TAG})
             if not tagname_re.match(tag):