diff options
author | 2015-05-12 02:17:30 +0200 | |
---|---|---|
committer | 2015-05-12 03:22:32 +0200 | |
commit | 000426c9d890ba2a71625a7454f9c573f10b9bae (patch) | |
tree | 8fa66da5061b850778f72f84038d9bb8bfa31f2f /pyload/manager/Event.py | |
parent | 'from os' -> 'import os' and so on... (diff) | |
download | pyload-000426c9d890ba2a71625a7454f9c573f10b9bae.tar.xz |
'from time' -> 'import time' and so on...
Diffstat (limited to 'pyload/manager/Event.py')
-rw-r--r-- | pyload/manager/Event.py | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/pyload/manager/Event.py b/pyload/manager/Event.py index b3d22619f..919835984 100644 --- a/pyload/manager/Event.py +++ b/pyload/manager/Event.py @@ -1,7 +1,8 @@ # -*- coding: utf-8 -*- # @author: mkaay -from time import time +import time + from pyload.utils import uniqify @@ -18,7 +19,7 @@ class PullManager(object): def clean(self): for n, client in enumerate(self.clients): - if client.lastActive + 30 < time(): + if client.lastActive + 30 < time.time(): del self.clients[n] @@ -27,7 +28,7 @@ class PullManager(object): validUuid = False for client in self.clients: if client.uuid == uuid: - client.lastActive = time() + client.lastActive = time.time() validUuid = True while client.newEvents(): events.append(client.popEvent().toList()) @@ -47,7 +48,7 @@ class Client(object): def __init__(self, uuid): self.uuid = uuid - self.lastActive = time() + self.lastActive = time.time() self.events = [] |