Skip to content

Commit 45ad33c

Browse files
authored
Merge pull request #270 from PyAutoLabs/feature/release-fixes-apr-2026
fix: guard zoom_array against non-autoarray mask objects
2 parents 78d06fd + 05314ac commit 45ad33c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

autoarray/plot/utils.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@ def zoom_array(array):
105105
except Exception:
106106
zoom_around_mask = False
107107

108-
if zoom_around_mask and hasattr(array, "mask") and not array.mask.is_all_false:
108+
if zoom_around_mask and hasattr(array, "mask") and hasattr(array.mask, "is_all_false") and not array.mask.is_all_false:
109109
from autoarray.mask.derive.zoom_2d import Zoom2D
110110

111111
return Zoom2D(mask=array.mask).array_2d_from(array=array, buffer=1)

0 commit comments

Comments
 (0)