CrAgr: fixed specific date parsing.
This commit is contained in:
parent
73f6617442
commit
a3d1c8daa5
1 changed files with 1 additions and 1 deletions
|
|
@ -277,7 +277,7 @@ class AccountsList(CragrBasePage):
|
|||
"""
|
||||
Builds a date object from a 'DD/MM' string
|
||||
"""
|
||||
matches = re.search('([012]?[0-9]|3[01])\s*/\s*(0?[1-9]|1[012])', string)
|
||||
matches = re.search('\s*([012]?[0-9]|3[01])\s*/\s*(0?[1-9]|1[012])\s*$', string)
|
||||
if matches is None:
|
||||
return self.fallback_date()
|
||||
return self.date_from_day_month(int(matches.group(1)), int(matches.group(2)))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue