Commit c95d739f authored by Pierre Dittgen's avatar Pierre Dittgen
Browse files

Fix TypeError: unsupported operand type(s) for -: 'NoneType' and 'int' bug

parent 81f84faa
......@@ -100,7 +100,7 @@ def contextualize(errors):
def add_context(err):
""" Adds context info based on row-nb presence """
context = 'body' if 'row-number' in err else 'table'
context = 'body' if 'row-number' in err and not err['row-number'] is None else 'table'
return {**err, 'context': context}
return list(map(add_context, errors))
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