Skip to content

Commit

Permalink
Fix FutureWarning in CFTimeIndex.date_type (pydata#2448)
Browse files Browse the repository at this point in the history
  • Loading branch information
spencerkclark authored and shoyer committed Sep 30, 2018
1 parent 23d1cda commit f9c4169
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion xarray/coding/cftimeindex.py
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,7 @@ def f(self):


def get_date_type(self):
if self.data:
if self._data.size:
return type(self._data[0])
else:
return None
Expand Down

0 comments on commit f9c4169

Please sign in to comment.