From 011efe42921080164dc3c3adb0126ccd48ad3f04 Mon Sep 17 00:00:00 2001 From: Faik Uygur Date: Tue, 11 Nov 2008 12:30:16 +0000 Subject: [PATCH] programming 101: know the library, use the library --- pisi/uri.py | 2 +- pisi/util.py | 5 ----- 2 files changed, 1 insertion(+), 6 deletions(-) diff --git a/pisi/uri.py b/pisi/uri.py index 06b92767..1614410d 100644 --- a/pisi/uri.py +++ b/pisi/uri.py @@ -70,7 +70,7 @@ class URI(object): return not self.is_local_file() def is_absolute_path(self): - return util.absolute_path(self.__path) + return os.path.isabs(self.__path) def is_relative_path(self): return not self.is_absolute_path() diff --git a/pisi/util.py b/pisi/util.py index c52cba24..ca7e1690 100644 --- a/pisi/util.py +++ b/pisi/util.py @@ -222,11 +222,6 @@ def removepathprefix(prefix, path): else: return "" -def absolute_path(path): - """Determine if given path is absolute.""" - comps = splitpath(path) - return comps[0] == '' - def join_path(a, *p): """Join two or more pathname components.