Skip to content

Commit 8492e1e

Browse files
simpify if clause
1 parent 820da18 commit 8492e1e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

pandas/io/formats/csvs.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ def __init__(self, obj, path_or_buf=None, sep=",", na_rep='',
5353
# if index label is not explicitly called, index label is True if
5454
# header or index is not False; otherwise, index label is set to False
5555
if index_label is None:
56-
if self.header is False or self.header is None or not self.index:
56+
if not self.header or not self.index:
5757
self.index_label = False
5858
else:
5959
self.index_label = True

0 commit comments

Comments
 (0)