Make pep8 happy

pull/8/head
Raphaël Vinot 2016-03-21 14:55:41 +01:00
parent bc655cedbf
commit a0c91e5c37
1 changed files with 8 additions and 9 deletions

View File

@ -233,7 +233,6 @@ class PyMISP(object):
else: else:
return session.post(url, data=event) return session.post(url, data=event)
def update_event(self, event_id, event, force_out=None): def update_event(self, event_id, event, force_out=None):
""" """
Update an event Update an event
@ -266,7 +265,6 @@ class PyMISP(object):
url = urljoin(self.root_url, 'attributes/{}'.format(attribute_id)) url = urljoin(self.root_url, 'attributes/{}'.format(attribute_id))
return session.delete(url) return session.delete(url)
# ############################################## # ##############################################
# ######### Event handling (Json only) ######### # ######### Event handling (Json only) #########
# ############################################## # ##############################################
@ -306,7 +304,7 @@ class PyMISP(object):
distribution = int(distribution) distribution = int(distribution)
# If None: take the default value of the event # If None: take the default value of the event
if distribution not in [None, 0, 1, 2, 3, 5]: if distribution not in [None, 0, 1, 2, 3, 5]:
raise NewAttributeError('{} is invalid, the distribution has to be in 0, 1, 2, 3 or None'.format(distribution)) raise NewAttributeError('{} is invalid, the distribution has to be in 0, 1, 2, 3, 5 or None'.format(distribution))
if distribution is not None: if distribution is not None:
to_return['distribution'] = distribution to_return['distribution'] = distribution
@ -901,6 +899,7 @@ class PyMISP(object):
response = session.get(url) response = session.get(url)
return response return response
# ############## Deprecated (Pure XML API should not be used) ################## # ############## Deprecated (Pure XML API should not be used) ##################
@deprecated @deprecated
def download_all(self): def download_all(self):
""" """