Skip to content

Commit 521d513

Browse files
authored
Merge pull request #2037 from UV-CDAT/cdmsFileAxisgetitem
Fix not tuple instance condition for axis getitem call
2 parents a4c138f + 97c33e1 commit 521d513

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Packages/cdms2/Lib/axis.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2011,8 +2011,8 @@ def __getitem__(self, key):
20112011
else:
20122012
if isinstance(key, int) and key >= len(self):
20132013
raise IndexError, 'Index out of bounds: %d' % key
2014-
if isinstance(key, tuple):
2015-
key=(key,)
2014+
if not isinstance(key, tuple):
2015+
key=(key,)
20162016
return apply(self._obj_.getitem, key)
20172017
if self._data_ is None:
20182018
self._data_=self.getData()

0 commit comments

Comments
 (0)