From 755f1e037af25f25d5945d7f8d56d5b4b76e414d Mon Sep 17 00:00:00 2001 From: Andreas Gohr Date: Tue, 7 Mar 2006 19:47:06 +0100 Subject: clean media directories after medeia deletion FS#734 darcs-hash:20060307184706-7ad00-c57e9e6c54879afaf17858fe642478fcb91af983.gz --- inc/io.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'inc/io.php') diff --git a/inc/io.php b/inc/io.php index 9160f4718..1d458ace9 100644 --- a/inc/io.php +++ b/inc/io.php @@ -16,12 +16,12 @@ * @todo use safemode hack * @author Andreas Gohr */ -function io_sweepNS($id){ +function io_sweepNS($id,$basedir='datadir'){ global $conf; //scan all namespaces while(($id = getNS($id)) !== false){ - $dir = $conf['datadir'].'/'.utf8_encodeFN(str_replace(':','/',$id)); + $dir = $conf[$basedir].'/'.utf8_encodeFN(str_replace(':','/',$id)); //try to delete dir else return if(!@rmdir($dir)) return; -- cgit v1.2.3