diff options
Diffstat (limited to 'pyLoadCore.py')
-rwxr-xr-x | pyLoadCore.py | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/pyLoadCore.py b/pyLoadCore.py index 6df4816db..1bd194f94 100755 --- a/pyLoadCore.py +++ b/pyLoadCore.py @@ -586,12 +586,13 @@ class ServerMethods(): self.core.threadManager.pause = False def toggle_pause(self): - if self.core.threadManager.pause: - self.core.threadManager.pause = False - else: - self.core.threadManager.pause = True + self.core.threadManager.pause ^= True return self.core.threadManager.pause + def toggle_reconnect(self): + self.core.config["reconnect"]["activated"] ^= True + return self.core.config["reconnect"]["activated"] + def status_server(self): """ dict with current server status """ status = {} @@ -824,7 +825,7 @@ class ServerMethods(): def is_time_reconnect(self): start = self.core.config['reconnect']['startTime'].split(":") end = self.core.config['reconnect']['endTime'].split(":") - return compare_time(start, end) + return compare_time(start, end) and self.core.config["reconnect"]["activated"] def delete_finished(self): """ delete all finished links + packages, returns deleted packages """ |