Author: rflosi
Date: 2005-12-08 17:54:27 +0000 (Thu, 08 Dec 2005)
New Revision: 1378
Modified:
FormEncode/trunk/formencode/validators.py
Log:
convert fields to strings before calling strip in case them come in as integers
Modified: FormEncode/trunk/formencode/validators.py
===================================================================
--- FormEncode/trunk/formencode/validators.py 2005-12-08 17:50:20 UTC (rev
1377)
+++ FormEncode/trunk/formencode/validators.py 2005-12-08 17:54:27 UTC (rev
1378)
@@ -2210,8 +2210,8 @@
field_dict, state, error_dict=errors)
def _validateReturn(self, field_dict, state):
- ccExpiresMonth = field_dict[self.cc_expires_month_field].strip()
- ccExpiresYear = field_dict[self.cc_expires_year_field].strip()
+ ccExpiresMonth = str(field_dict[self.cc_expires_month_field]).strip()
+ ccExpiresYear = str(field_dict[self.cc_expires_year_field]).strip()
try:
ccExpiresMonth = int(ccExpiresMonth)
-------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems? Stop! Download the new AJAX search engine that makes
searching your log files as easy as surfing the web. DOWNLOAD SPLUNK!
http://ads.osdn.com/?ad_id=7637&alloc_id=16865&op=click
_______________________________________________
FormEncode-CVS mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/formencode-cvs