mirror of https://github.com/MISP/PyMISP
_default_attributes_parameters - if set - is a dict
Manage distribution and sharing_group_id as dict key like the other fields. -- Not sure about defaultpull/165/head
parent
c68b69b422
commit
94cd2fd52e
|
@ -784,8 +784,8 @@ class MISPObject(AbstractMISP):
|
||||||
self._default_attributes_parameters.pop('category', None) # depends on the value
|
self._default_attributes_parameters.pop('category', None) # depends on the value
|
||||||
self._default_attributes_parameters.pop('deleted', None) # doesn't make sense to pre-set it
|
self._default_attributes_parameters.pop('deleted', None) # doesn't make sense to pre-set it
|
||||||
self._default_attributes_parameters.pop('data', None) # in case the original in a sample or an attachment
|
self._default_attributes_parameters.pop('data', None) # in case the original in a sample or an attachment
|
||||||
self.distribution = self._default_attributes_parameters.distribution
|
self.distribution = self._default_attributes_parameters.pop('distribution', 5)
|
||||||
self.sharing_group_id = self._default_attributes_parameters.sharing_group_id
|
self.sharing_group_id = self._default_attributes_parameters.pop('sharing_group_id', None)
|
||||||
else:
|
else:
|
||||||
self.distribution = 5 # Default to inherit
|
self.distribution = 5 # Default to inherit
|
||||||
self.sharing_group_id = None
|
self.sharing_group_id = None
|
||||||
|
|
Loading…
Reference in New Issue