From 8f722809482fb71a18498ceb58f4ca17f60ca5a1 Mon Sep 17 00:00:00 2001 From: Viktor van Wijk Date: Fri, 20 Dec 2024 16:56:57 +0100 Subject: [PATCH] :bug: [#4908] Bug fix in adding variables to values dict --- src/openforms/registrations/contrib/json/plugin.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/openforms/registrations/contrib/json/plugin.py b/src/openforms/registrations/contrib/json/plugin.py index 94f74ee5fc..b4bc902667 100644 --- a/src/openforms/registrations/contrib/json/plugin.py +++ b/src/openforms/registrations/contrib/json/plugin.py @@ -36,11 +36,10 @@ def register_submission(self, submission: Submission, options: JSONOptions) -> N } # Update values dict with relevant form data + all_variables = {**submission.data, **static_variables_dict} values.update( { - form_variable: submission.data.get( - form_variable, static_variables_dict[form_variable] - ) + form_variable: all_variables[form_variable] for form_variable in options["form_variables"] } )