hope I got the merge wright...
[monitor.git] / monitor / util / __init__.py
index 8986f7f..c5a3dfd 100644 (file)
@@ -1,8 +1,10 @@
-__all__=["writepid","removepid","daemonize"]
 
 import time
 import math
 
+# import local file.py
+import file
+
 def diff_time(timestamp, abstime=True):
        now = time.time()
        if timestamp == None:
@@ -26,8 +28,8 @@ def diff_time(timestamp, abstime=True):
                t = diff / (60*60*24)
                t_str = "%s days ago" % int(math.ceil(t))
        elif diff <= 60*60*24*30: # approx sec in month
-               t = diff / (60*60*24*7)
-               t_str = "%s wks ago" % int(math.ceil(t))
+               t = diff / (60*60*24)
+               t_str = "%s days ago" % int(math.ceil(t))
        elif diff > 60*60*24*30: # approx sec in month
                t = diff / (60*60*24*30)
                t_str = "%s mnths ago" % int(t)