diff options
Diffstat (limited to 'src/tablib')
| -rw-r--r-- | src/tablib/formats/_rst.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/tablib/formats/_rst.py b/src/tablib/formats/_rst.py index 6dce91f..afbf1ca 100644 --- a/src/tablib/formats/_rst.py +++ b/src/tablib/formats/_rst.py @@ -24,7 +24,7 @@ def _max_word_len(text): >>> _max_word_len('Python Module for Tabular Datasets') 8 """ - return max(len(word) for word in text.split()) if text else 0 + return max([len(word) for word in text.split()], default=0) if text else 0 class ReSTFormat: |
