Browse Source

Fix field matching regex for source rewrite

pull/6/head
Marcio Mazza 10 years ago
parent
commit
9011bba170
  1. 2
      legacy/scripts/scrap_original_forms.py

2
legacy/scripts/scrap_original_forms.py

@ -100,7 +100,7 @@ def source_with_verbose_names(model):
for line in source[1:]: for line in source[1:]:
for regex, split in [ for regex, split in [
(field_regex + ' *# (.+)', lambda groups: groups), (field_regex + ' *# (.+)', lambda groups: groups),
(field_regex, lambda groups: groups + [''])]: (field_regex, lambda groups: groups + ('',))]:
match = re.match(regex, line) match = re.match(regex, line)
if match: if match:
name, path, args, legacy_name = split(match.groups()) name, path, args, legacy_name = split(match.groups())

Loading…
Cancel
Save