rest_client.py
updated for connection error case
This commit is contained in:
parent
b1761b1602
commit
596cda78b6
@ -184,7 +184,9 @@ class FtRestClient():
|
|||||||
|
|
||||||
def ping(self):
|
def ping(self):
|
||||||
"""simple ping"""
|
"""simple ping"""
|
||||||
if self.show_config()['state'] == "running":
|
if not self.show_config():
|
||||||
|
return {"status": "not_running"}
|
||||||
|
elif self.show_config()['state'] == "running":
|
||||||
return {"status": "pong"}
|
return {"status": "pong"}
|
||||||
else:
|
else:
|
||||||
return {"status": "not_running"}
|
return {"status": "not_running"}
|
||||||
|
Loading…
Reference in New Issue
Block a user