Fix regexp for date
This commit is contained in:
parent
5cd5c1791b
commit
5f44d874d6
1 changed files with 1 additions and 2 deletions
|
@ -159,8 +159,7 @@ class image_classifier:
|
||||||
if file_date is None:
|
if file_date is None:
|
||||||
self._log.debug('Date not stored in EXIF metadata')
|
self._log.debug('Date not stored in EXIF metadata')
|
||||||
match = re.search(
|
match = re.search(
|
||||||
r'(?P<year>20[0-9]{2})[\-/\._]?(?P<month>[0-1]?[0-9])\
|
r'(?P<year>20[0-9]{2})[\-/\._]?(?P<month>[0-1]?[0-9])[\-/\._]?(?P<day>[0-3]?[0-9])[\-/\._]?(?P<hour>[0-2]?[0-9])?[\-/\._]?(?P<minute>[0-6]?[0-9])?[\-/\._]?(?P<second>[0-6]?[0-9])?',
|
||||||
[\-/\._]?(?P<day>[0-3]?[0-9])',
|
|
||||||
filename
|
filename
|
||||||
)
|
)
|
||||||
if match:
|
if match:
|
||||||
|
|
Loading…
Reference in a new issue