@@ -364,43 +364,43 @@ def import_from_stix2(self, **kwargs):
364364 if stix_object is not None :
365365 # Search in extensions
366366 if "x_opencti_score" not in stix_object :
367- stix_object [
368- "x_opencti_score"
369- ] = self . opencti . get_attribute_in_extension ( "score" , stix_object )
367+ stix_object ["x_opencti_score" ] = (
368+ self . opencti . get_attribute_in_extension ( "score" , stix_object )
369+ )
370370 if "x_opencti_detection" not in stix_object :
371- stix_object [
372- "x_opencti_detection"
373- ] = self . opencti . get_attribute_in_extension ( "detection" , stix_object )
371+ stix_object ["x_opencti_detection" ] = (
372+ self . opencti . get_attribute_in_extension ( "detection" , stix_object )
373+ )
374374 if (
375375 "x_opencti_main_observable_type" not in stix_object
376376 and self .opencti .get_attribute_in_extension (
377377 "main_observable_type" , stix_object
378378 )
379379 is not None
380380 ):
381- stix_object [
382- "x_opencti_main_observable_type"
383- ] = self . opencti . get_attribute_in_extension (
384- "main_observable_type" , stix_object
381+ stix_object ["x_opencti_main_observable_type" ] = (
382+ self . opencti . get_attribute_in_extension (
383+ "main_observable_type" , stix_object
384+ )
385385 )
386386 if "x_opencti_create_observables" not in stix_object :
387- stix_object [
388- "x_opencti_create_observables"
389- ] = self . opencti . get_attribute_in_extension (
390- "create_observables" , stix_object
387+ stix_object ["x_opencti_create_observables" ] = (
388+ self . opencti . get_attribute_in_extension (
389+ "create_observables" , stix_object
390+ )
391391 )
392392 if "x_opencti_stix_ids" not in stix_object :
393- stix_object [
394- "x_opencti_stix_ids"
395- ] = self . opencti . get_attribute_in_extension ( "stix_ids" , stix_object )
393+ stix_object ["x_opencti_stix_ids" ] = (
394+ self . opencti . get_attribute_in_extension ( "stix_ids" , stix_object )
395+ )
396396 if "x_opencti_granted_refs" not in stix_object :
397- stix_object [
398- "x_opencti_granted_refs"
399- ] = self . opencti . get_attribute_in_extension ( "granted_refs" , stix_object )
397+ stix_object ["x_opencti_granted_refs" ] = (
398+ self . opencti . get_attribute_in_extension ( "granted_refs" , stix_object )
399+ )
400400 if "x_opencti_workflow_id" not in stix_object :
401- stix_object [
402- "x_opencti_workflow_id"
403- ] = self . opencti . get_attribute_in_extension ( "workflow_id" , stix_object )
401+ stix_object ["x_opencti_workflow_id" ] = (
402+ self . opencti . get_attribute_in_extension ( "workflow_id" , stix_object )
403+ )
404404
405405 return self .create (
406406 stix_id = stix_object ["id" ],
0 commit comments