lists.arthurdejong.org
RSS feed

python-stdnum commit: r163 - python-stdnum/stdnum/cz

[Date Prev][Date Next] [Thread Prev][Thread Next]

python-stdnum commit: r163 - python-stdnum/stdnum/cz



Author: arthur
Date: Fri Feb 24 21:54:55 2012
New Revision: 163
URL: http://arthurdejong.org/viewvc/python-stdnum?revision=163&view=revision

Log:
make the get_birth_date() function publically available

Modified:
   python-stdnum/stdnum/cz/rc.py

Modified: python-stdnum/stdnum/cz/rc.py
==============================================================================
--- python-stdnum/stdnum/cz/rc.py       Fri Feb 24 21:43:25 2012        (r162)
+++ python-stdnum/stdnum/cz/rc.py       Fri Feb 24 21:54:55 2012        (r163)
@@ -50,7 +50,7 @@
     return clean(number, ' /').upper().strip()
 
 
-def _get_birth_date(number):
+def get_birth_date(number):
     """Split the date parts from the number and return the birth date."""
     year = 1900 + int(number[0:2])
     # females have 50 added to the month value, 20 is added when the serial
@@ -79,7 +79,7 @@
         return False
     # check if birth date is valid
     try:
-        birth_date = _get_birth_date(number)
+        birth_date = get_birth_date(number)
         # TODO: check that the birth date is not in the future
     except ValueError, e:
         return False
-- 
To unsubscribe send an email to
python-stdnum-commits-unsubscribe@lists.arthurdejong.org or see
http://lists.arthurdejong.org/python-stdnum-commits/