Skip to content

Commit

Permalink
Merge branch 'master' of github.com:oasis-open/cti-python-stix2
Browse files Browse the repository at this point in the history
  • Loading branch information
chrisr3d committed Jul 1, 2019
2 parents 565acc7 + 244d8c9 commit b204b9f
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion stix2/v20/bundle.py
Expand Up @@ -43,7 +43,7 @@ def __init__(self, *args, **kwargs):

def get_obj(self, obj_uuid):
if "objects" in self._inner:
found_objs = [elem for elem in self.objects if elem.id == obj_uuid]
found_objs = [elem for elem in self.objects if elem['id'] == obj_uuid]
if found_objs == []:
raise KeyError("'%s' does not match the id property of any of the bundle's objects" % obj_uuid)
return found_objs
Expand Down
2 changes: 1 addition & 1 deletion stix2/v21/bundle.py
Expand Up @@ -41,7 +41,7 @@ def __init__(self, *args, **kwargs):

def get_obj(self, obj_uuid):
if "objects" in self._inner:
found_objs = [elem for elem in self.objects if elem.id == obj_uuid]
found_objs = [elem for elem in self.objects if elem['id'] == obj_uuid]
if found_objs == []:
raise KeyError("'%s' does not match the id property of any of the bundle's objects" % obj_uuid)
return found_objs
Expand Down

0 comments on commit b204b9f

Please sign in to comment.