fix: Fixed object_id variable name typo

pull/304/head
root 2019-04-01 16:28:19 +02:00
parent d87a67c6f3
commit 2439d5f75d
No known key found for this signature in database
GPG Key ID: 6BBED1B63A6D639F
1 changed files with 1 additions and 1 deletions

View File

@ -62,7 +62,7 @@ class PayloadQuery(URLhaus):
hash_type = self.attribute.type
file_object = MISPObject('file')
if self.attribute.event_id != '0':
file_object.id = self.attribute.event_id
file_object.id = self.attribute.object_id
response = requests.post(self.url, data={'{}_hash'.format(hash_type): self.attribute.value}).json()
other_hash_type = 'md5' if hash_type == 'sha256' else 'sha256'
for key, relation in zip(('{}_hash'.format(other_hash_type), 'file_size'), (other_hash_type, 'size-in-bytes')):