Skip to content
Snippets Groups Projects
Commit 32d2de15 authored by Jan Prachař's avatar Jan Prachař
Browse files

revert regexp na apostrofy

parent eb31cd8e
No related branches found
No related tags found
No related merge requests found
This commit is part of merge request !39. Comments created here will be created in the context of that merge request.
...@@ -163,7 +163,7 @@ class Import: ...@@ -163,7 +163,7 @@ class Import:
# Ve snaze zabránit Excelu v interpretování ročníku jako kalendářního data # Ve snaze zabránit Excelu v interpretování ročníku jako kalendářního data
# lidé připisují všechny možné i nemožné znaky, které vypadají jako apostrof :) # lidé připisují všechny možné i nemožné znaky, které vypadají jako apostrof :)
rocnik = re.sub('^[^\d]', "", rocnik) rocnik = re.sub('[\'"\u00b4\u2019]', "", rocnik)
if (not re.fullmatch(r'\d(/\d)?', rocnik)): if (not re.fullmatch(r'\d(/\d)?', rocnik)):
return self.error(f'Ročník má neplatný formát, musí to být buď číslice, nebo číslice/číslice') return self.error(f'Ročník má neplatný formát, musí to být buď číslice, nebo číslice/číslice')
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment