Skip to content
This repository was archived by the owner on Dec 5, 2025. It is now read-only.

Commit 6ae5175

Browse files
committed
[client] style
1 parent bb5b501 commit 6ae5175

File tree

1 file changed

+3
-9
lines changed

1 file changed

+3
-9
lines changed

pycti/utils/opencti_stix2.py

Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -2492,17 +2492,13 @@ def apply_patch(self, item):
24922492
self.apply_patch_files(item)
24932493

24942494
def rule_apply(self, item):
2495-
rule_id = self.opencti.get_attribute_in_extension(
2496-
"opencti_rule", item
2497-
)
2495+
rule_id = self.opencti.get_attribute_in_extension("opencti_rule", item)
24982496
if rule_id is None:
24992497
rule_id = item["opencti_rule"]
25002498
self.opencti.stix_core_object.rule_apply(element_id=item["id"], rule_id=rule_id)
25012499

25022500
def rule_clear(self, item):
2503-
rule_id = self.opencti.get_attribute_in_extension(
2504-
"opencti_rule", item
2505-
)
2501+
rule_id = self.opencti.get_attribute_in_extension("opencti_rule", item)
25062502
if rule_id is None:
25072503
rule_id = item["opencti_rule"]
25082504
self.opencti.stix_core_object.rule_clear(element_id=item["id"], rule_id=rule_id)
@@ -2563,9 +2559,7 @@ def apply_opencti_operation(self, item, operation):
25632559
elif item["opencti_operation"] == "restore":
25642560
self.opencti.trash.restore(item["id"])
25652561
elif item["opencti_operation"] == "merge":
2566-
target_id = self.opencti.get_attribute_in_extension(
2567-
"merge_target_id", item
2568-
)
2562+
target_id = self.opencti.get_attribute_in_extension("merge_target_id", item)
25692563
if target_id is None:
25702564
target_id = item["merge_target_id"]
25712565
source_ids = self.opencti.get_attribute_in_extension(

0 commit comments

Comments
 (0)