From a44573f65f05360f428dd7a1e3ae7ca2161699f0 Mon Sep 17 00:00:00 2001 From: Paul McCarthy <pauldmccarthy@gmail.com> Date: Tue, 29 Mar 2022 17:15:02 +0100 Subject: [PATCH] BF: wrong logic --- fsl/data/image.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/fsl/data/image.py b/fsl/data/image.py index 12deb658e..a9dce5de2 100644 --- a/fsl/data/image.py +++ b/fsl/data/image.py @@ -1310,7 +1310,7 @@ class Image(Nifti): if self.__dataMgr is not None: return self[:] - if self.__data is not None: + if self.__data is None: self.__data = self[:] return self.__data @@ -1443,8 +1443,8 @@ class Image(Nifti): # expects (data, affine, header) if not self.saveState: self.__nibImage = type(self.__nibImage)(self.data, - None, - self.header) + affine=None, + header=self.header) self.header = self.__nibImage.header nib.save(self.__nibImage, tmpfname) -- GitLab