Skip to content

Commit 0b3c262

Browse files
committed
Do not open HDF5 browser when no files are selected
1 parent aefe662 commit 0b3c262

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

cdl/core/gui/main.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1329,6 +1329,8 @@ def open_h5_files(
13291329
h5files, _fl = getopenfilenames(
13301330
self, _("Open"), basedir, _("HDF5 files (*.h5 *.hdf5)")
13311331
)
1332+
if not h5files:
1333+
return
13321334
filenames, dsetnames = [], []
13331335
for fname_with_dset in h5files:
13341336
if "," in fname_with_dset:

0 commit comments

Comments
 (0)