Skip to content

Commit

Permalink
Adding assert on length
Browse files Browse the repository at this point in the history
  • Loading branch information
tdegeus committed Mar 4, 2022
1 parent ca0f638 commit 6478ffb
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions GooseHDF5/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -579,6 +579,9 @@ def copy(
:param recursive: If the source is a group, copy all objects within that group recursively.
"""

if len(source_datasets) == 0:
return

source_datasets = np.array([abspath(path) for path in source_datasets])

if not dest_datasets:
Expand Down

0 comments on commit 6478ffb

Please sign in to comment.