Changeset 320
- Timestamp:
- 06/24/08 16:05:01 (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/plugins/svnpoliciesplugin/svnpolicies/admin.py
r63 r320 28 28 """ 29 29 action_status= None 30 valid_email_flag = None31 30 errors= False 32 31 … … 130 129 131 130 self.action_status = [] 132 self.valid_email_flag = True133 131 self.errors = False 134 132 … … 191 189 self.errors = True 192 190 193 # email list194 try:195 for email in string.split(req.args.get('email_list'), ','):196 if len(email) and not pm.validate_email(email):197 raise Exception('invalid')198 except Exception, e:199 self.action_status.append('Email list must contain a ' +200 'comma seperated list of valid email addresses. ' +201 '[%s] is not valid'%(email))202 self.errors = True203 204 # email from address205 try:206 if len(req.args.get('email_from_address')):207 if not pm.validate_email(req.args.get('email_from_address')):208 raise Exception('invalid')209 except Exception, e:210 self.action_status.append('From email must be a ' +211 'valid email addresses')212 self.errors = True213 214 191 if self.errors: 215 192 self.log.warning('validation errors occured: ')
Note: See TracChangeset
for help on using the changeset viewer.
