Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit f6d425f

Browse files
lpsingertimhoffm
andauthored
Update lib/matplotlib/figure.py
Co-authored-by: Tim Hoffmann <[email protected]>
1 parent 3e078bc commit f6d425f

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

lib/matplotlib/figure.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1467,10 +1467,9 @@ def _gci(self):
14671467
``gci`` (get current image).
14681468
"""
14691469
# Look first for an image in the current Axes:
1470-
cax = self._axstack()
1471-
if cax is None:
1470+
if self._axstack.empty():
14721471
return None
1473-
im = cax._gci()
1472+
im = self._axstack()._gci()
14741473
if im is not None:
14751474
return im
14761475

0 commit comments

Comments
 (0)