Skip to content

Commit 58053ea

Browse files
author
mcramer
committed
Bugfix: Web folder protection did not work on web deletion
Bugfix: $app->system->unlink function had wrong parameter name, no files were deleted ever
1 parent 6ac26d6 commit 58053ea

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

server/lib/classes/system.inc.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -699,7 +699,7 @@ function mkdir($dirname, $allow_symlink = false) {
699699
}
700700
}
701701

702-
function unlink($file) {
702+
function unlink($filename) {
703703
if(file_exists($filename)) {
704704
return unlink($filename);
705705
}

server/plugins-available/apache2_plugin.inc.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1452,7 +1452,7 @@ function delete($event_name,$data) {
14521452
$app->uses('system');
14531453
$web_config = $app->getconf->get_server_config($conf['server_id'], 'web');
14541454

1455-
$app->system->web_folder_protection($data['new']['document_root'],false);
1455+
$app->system->web_folder_protection($data['old']['document_root'],false);
14561456

14571457
//* Check if this is a chrooted setup
14581458
if($web_config['website_basedir'] != '' && @is_file($web_config['website_basedir'].'/etc/passwd')) {

0 commit comments

Comments
 (0)