mirror of https://github.com/MISP/PyMISPGalaxies
chg: [Cluster] duplicates are CaSe InSenSiTiVe
parent
4a35a5a16d
commit
47ed9cb26f
|
@ -528,7 +528,7 @@ class Cluster(Mapping): # type: ignore
|
||||||
self.duplicates.append((self.name, cv.value))
|
self.duplicates.append((self.name, cv.value))
|
||||||
else:
|
else:
|
||||||
raise PyMISPGalaxiesError("Duplicate value ({}) in cluster: {}".format(cv.value, self.name))
|
raise PyMISPGalaxiesError("Duplicate value ({}) in cluster: {}".format(cv.value, self.name))
|
||||||
self.cluster_values[cv.value] = cv
|
self.cluster_values[cv.value.lower()] = cv
|
||||||
|
|
||||||
def save(self, name: str) -> None:
|
def save(self, name: str) -> None:
|
||||||
"""
|
"""
|
||||||
|
@ -562,7 +562,7 @@ class Cluster(Mapping): # type: ignore
|
||||||
Returns:
|
Returns:
|
||||||
ClusterValue: The cluster value with the specified name.
|
ClusterValue: The cluster value with the specified name.
|
||||||
"""
|
"""
|
||||||
return self.cluster_values[name]
|
return self.cluster_values[name.lower()]
|
||||||
|
|
||||||
def __len__(self) -> int:
|
def __len__(self) -> int:
|
||||||
"""
|
"""
|
||||||
|
|
Loading…
Reference in New Issue