Merge pull request #1 from BjornArnelid/master

Indentation corrected, and replaced tab with four spaces.
This commit is contained in:
Guillaume Destuynder 2014-04-21 10:02:27 -07:00
Родитель 1a9bb2678e 520defd301
Коммит da6e2d35be
1 изменённых файлов: 4 добавлений и 4 удалений

Просмотреть файл

@ -14,9 +14,9 @@ import pytz
import json import json
import socket import socket
try: try:
from requests_futures.sessions import FuturesSession as Session from requests_futures.sessions import FuturesSession as Session
except ImportError: except ImportError:
from requests import Session from requests import Session
class MozDefError(Exception): class MozDefError(Exception):
def __init__(self, msg): def __init__(self, msg):
@ -78,8 +78,8 @@ class MozDefMsg():
raise MozDefError('Summary is a required field') raise MozDefError('Summary is a required field')
if self.debug: if self.debug:
print(json.dumps(log_msg, sort_keys=True, indent=4)) print(json.dumps(log_msg, sort_keys=True, indent=4))
return return
try: try:
r = self.httpsession.post(self.mozdef_hostname, json.dumps(log_msg, sort_keys=True, indent=4), verify=self.verify_certificate, background_callback=self.httpsession_cb) r = self.httpsession.post(self.mozdef_hostname, json.dumps(log_msg, sort_keys=True, indent=4), verify=self.verify_certificate, background_callback=self.httpsession_cb)