From c7d6c70d7f11856b9ccb67ef919fe7b07b1dfcae Mon Sep 17 00:00:00 2001 From: Denys Savchenko <56398430+dsavchenko@users.noreply.github.com> Date: Fri, 15 Nov 2024 21:27:18 +0100 Subject: [PATCH] Update cdci_data_analysis/analysis/parameters.py Co-authored-by: Gabriele Barni --- cdci_data_analysis/analysis/parameters.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cdci_data_analysis/analysis/parameters.py b/cdci_data_analysis/analysis/parameters.py index 1b52f937..c11d1e6b 100644 --- a/cdci_data_analysis/analysis/parameters.py +++ b/cdci_data_analysis/analysis/parameters.py @@ -621,7 +621,7 @@ def __init__(self, *args, **kwargs): kwargs['allowed_types'] = [int, float] if kwargs.get('default_type') is None: - val = kwargs['value'] if 'value' in kwargs.keys() else args[0] + val = kwargs.get('value', args[0]) if type(val) in kwargs['allowed_types']: kwargs['default_type'] = type(val) else: