From 58c0e9059a415dbf9e81d70320b19e635d74c96e Mon Sep 17 00:00:00 2001 From: pedro Date: Thu, 26 Sep 2024 00:10:48 -0300 Subject: [PATCH] device: avoid hids duplication --- device/models.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/device/models.py b/device/models.py index c9e04ec..9972ef5 100644 --- a/device/models.py +++ b/device/models.py @@ -89,10 +89,10 @@ class Device: def get_hids(self): annotations = self.get_annotations() - self.hids = annotations.filter( + self.hids = list(set(annotations.filter( type=Annotation.Type.SYSTEM, key__in=ALGOS.keys(), - ).values_list("value", flat=True) + ).values_list("value", flat=True))) def get_evidences(self): if not self.uuids: