Commit cd753510 authored by Christophe Benz's avatar Christophe Benz
Browse files

Check if cell has a value

parent 6296e5b1
...@@ -37,7 +37,8 @@ class ExtraOrMissingHeader(object): ...@@ -37,7 +37,8 @@ class ExtraOrMissingHeader(object):
extra_headers = headers_set - field_names_set extra_headers = headers_set - field_names_set
if extra_headers: if extra_headers:
for cell in cells: for cell in cells:
if cell['value'] in extra_headers: value = cell.get('value')
if value is not None and value in extra_headers:
errors.append(Error(code='extra-header', cell=cell)) errors.append(Error(code='extra-header', cell=cell))
if field_names_set == headers_set and field_names != headers: if field_names_set == headers_set and field_names != headers:
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment