Skip to content

Commit bebdfcf

Browse files
committed
TYP: nlevels and _has_aliases
1 parent 1346995 commit bebdfcf

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

pandas/io/formats/csvs.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -222,14 +222,14 @@ def data_index(self) -> Index:
222222
return data_index
223223

224224
@property
225-
def nlevels(self):
225+
def nlevels(self) -> int:
226226
if self.index:
227227
return getattr(self.data_index, "nlevels", 1)
228228
else:
229229
return 0
230230

231231
@property
232-
def _has_aliases(self):
232+
def _has_aliases(self) -> bool:
233233
return isinstance(self.header, (tuple, list, np.ndarray, ABCIndexClass))
234234

235235
@property

0 commit comments

Comments
 (0)