dosyayı silmeden önce var olup olmadığına bakmak lazımdır.
This commit is contained in:
+4
-2
@@ -58,7 +58,9 @@ def remove(pkg):
|
|||||||
def purge(pkg):
|
def purge(pkg):
|
||||||
if d.has_key(pkg):
|
if d.has_key(pkg):
|
||||||
(status, version, release) = d[pkg]
|
(status, version, release) = d[pkg]
|
||||||
os.unlink(files_name(pkg, version, release))
|
f = files_name(pkg, version, release)
|
||||||
del d[pkg]
|
if util.check_file(f):
|
||||||
|
os.unlink(f)
|
||||||
|
del d[pkg]
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user