diff --git a/src/pynwb/image.py b/src/pynwb/image.py index f48b3a667..75d2c1fe9 100644 --- a/src/pynwb/image.py +++ b/src/pynwb/image.py @@ -150,9 +150,9 @@ def _check_external_file_starting_frame_length(self): the number of files in 'external_file'. """ if self.external_file is None: - return True + return if get_data_shape(self.external_file) == get_data_shape(self.starting_frame): - return True + return return ( "%s '%s': The number of frame indices in 'starting_frame' should have " @@ -164,7 +164,7 @@ def _check_external_file_format(self): Check that format is 'external' when external_file is specified. """ if self.external_file is None: - return + return if self.format == "external": return