cleaner code

This commit is contained in:
John-Paul Compagnone
2024-04-11 11:06:45 -04:00
parent 3b127b6862
commit 81b77f8768

View File

@@ -326,13 +326,9 @@ class ePIC(BaseMiner):
if web_summary is not None: if web_summary is not None:
try: try:
op_state = web_summary["Status"]["Operating State"] op_state = web_summary["Status"]["Operating State"]
return not op_state == "Idling"
except KeyError: except KeyError:
return None
pass pass
if op_state != "Idling":
return True
else:
return False
async def _get_uptime(self, web_summary: dict = None) -> Optional[int]: async def _get_uptime(self, web_summary: dict = None) -> Optional[int]:
if web_summary is None: if web_summary is None: