Skip to content

Commit ec0cd91

Browse files
committed
Fix key check
1 parent 43f0002 commit ec0cd91

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

mwrpy/level1/write_lev1_nc.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -187,7 +187,7 @@ def prepare_data(
187187

188188
file_list_abscal = (
189189
get_file_list(params["path_to_cal"] + "COVARIANCE/", "LOG")
190-
if params["path_to_cal"] is not None
190+
if params.get("path_to_cal") is not None
191191
else []
192192
)
193193
for cal in ["ln2", "amb"]:
@@ -302,7 +302,7 @@ def prepare_data(
302302

303303
elif data_type in ("cov", "his"):
304304
rpg_cov = {}
305-
if date is not None and params["path_to_cal"] is not None:
305+
if date is not None and params.get("path_to_cal") is not None:
306306
file_list_abscal = get_file_list(
307307
params["path_to_cal"] + "COVARIANCE/", "LOG"
308308
)

0 commit comments

Comments
 (0)