diff --git a/fsl/wrappers/wrapperutils.py b/fsl/wrappers/wrapperutils.py
index c89afb2aadb002e1e6838235578ce124ce4caf41..81fb86826849b6a4eb55c9012f71c0c61cf40cc6 100644
--- a/fsl/wrappers/wrapperutils.py
+++ b/fsl/wrappers/wrapperutils.py
@@ -952,16 +952,17 @@ def fileOrImage(*args, **kwargs):
 
         # create an independent in-memory
         # copy of the image file
-        img = nib.load(path, mmap=False)
+        img  = nib.load(path, mmap=False)
+        data = np.asanyarray(img.dataobj)
 
         # if any arguments were fsl images,
         # that takes precedence.
         if fslimage.Image in intypes:
-            return fslimage.Image(img.get_data(), header=img.header)
+            return fslimage.Image(data, header=img.header)
         # but if all inputs were file names,
         # nibabel takes precedence
         elif nib.nifti1.Nifti1Image in intypes or len(intypes) == 0:
-            return nib.nifti1.Nifti1Image(img.get_data(), None, img.header)
+            return nib.nifti1.Nifti1Image(data, None, img.header)
 
         # this function should not be called
         # under any other circumstances