avoid serializing the bpmn process instance just to save data w/ burnettk

This commit is contained in:
jasquat 2023-11-16 12:32:38 -05:00
parent d9203f4d37
commit 9f58c7405d
1 changed files with 1 additions and 2 deletions

View File

@ -516,8 +516,7 @@ class TaskService:
) -> JsonDataDict | None: ) -> JsonDataDict | None:
data_dict_to_use = bpmn_process_data_dict data_dict_to_use = bpmn_process_data_dict
if bpmn_process_instance is not None: if bpmn_process_instance is not None:
serialized_bpmn_process = self.serializer.to_dict(bpmn_process_instance) data_dict_to_use = self.serializer.to_dict(bpmn_process_instance.data)
data_dict_to_use = serialized_bpmn_process.pop("data")
if data_dict_to_use is None: if data_dict_to_use is None:
data_dict_to_use = {} data_dict_to_use = {}
bpmn_process_data_json = json.dumps(data_dict_to_use, sort_keys=True) bpmn_process_data_json = json.dumps(data_dict_to_use, sort_keys=True)