redo new logging
parent
a5a50a84d4
commit
0b34951423
|
@ -131,7 +131,7 @@ def raw(data, fd = sys.stdout, terminal = False):
|
|||
Outputs raw data to console without formatting
|
||||
'''
|
||||
|
||||
if (get_settings() & OUTPUT_TO_CONSOLE):
|
||||
if terminal and (get_settings() & OUTPUT_TO_CONSOLE):
|
||||
try:
|
||||
ts = fd.write('%s\n' % data)
|
||||
except OSError:
|
||||
|
|
|
@ -19,7 +19,6 @@ def local_command(core_inst, command, data='', silent = True, post=False, postDa
|
|||
if data != '':
|
||||
data = '&data=' + urllib.parse.quote_plus(data)
|
||||
payload = 'http://%s/%s%s' % (hostname, command, data)
|
||||
print(payload)
|
||||
try:
|
||||
if post:
|
||||
retData = requests.post(payload, data=postData, headers={'token': core_inst.config.get('client.webpassword'), 'Connection':'close'}, timeout=(maxWait, maxWait)).text
|
||||
|
|
Loading…
Reference in New Issue