From 8c066e79b03ad4e20a9f7c4ae36a9e247b79a8eb Mon Sep 17 00:00:00 2001 From: necoro <> Date: Mon, 27 Aug 2007 07:30:38 +0000 Subject: Change to absolute_imports; Warning: definitly broken --- portato/plistener.py | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'portato/plistener.py') diff --git a/portato/plistener.py b/portato/plistener.py index 1cd7529..452bee6 100644 --- a/portato/plistener.py +++ b/portato/plistener.py @@ -10,6 +10,8 @@ # # Written by René 'Necoro' Neumann +from __future__ import absolute_import + import socket, os from subprocess import Popen from gettext import lgettext as _ @@ -19,8 +21,8 @@ try: except ImportError: pynotify = None -from constants import SOCKET, APP -from helper import debug, warning +from .constants import SOCKET, APP +from .helper import debug, warning class PListener (object): """This class handles the communication between the "listener" and the GUI. @@ -77,7 +79,7 @@ class PListener (object): """Displays a notify. This will do nothing if pynotify is not present and/or root is running the listener.""" - if pynotify and not os.getuid == 0: + if pynotify and os.getuid() != 0: if not pynotify.is_initted(): pynotify.init(APP) -- cgit v1.2.3-70-g09d2