diff options
Diffstat (limited to 'phpBB/includes/functions_admin.php')
-rw-r--r-- | phpBB/includes/functions_admin.php | 12 |
1 files changed, 2 insertions, 10 deletions
diff --git a/phpBB/includes/functions_admin.php b/phpBB/includes/functions_admin.php index 03a89eca31..57643c8b98 100644 --- a/phpBB/includes/functions_admin.php +++ b/phpBB/includes/functions_admin.php @@ -677,16 +677,8 @@ function phpbb_unlink($filename, $mode = 'file') { global $config, $user, $phpbb_root_path; - $filename = ($mode == 'thumbnail') ? $phpbb_root_path . $config['upload_dir'] . '/thumb_' . basename($filename) : $phpbb_root_path . $config['upload_dir'] . '/' . basename($filename); - $deleted = @unlink($filename); - - if (file_exists($filename)) - { - $filesys = str_replace('/','\\', $filename); - $deleted = @system("del $filesys"); - } - - return $deleted; + $filename = ($mode == 'thumbnail') ? $phpbb_root_path . $config['upload_path'] . '/thumb_' . basename($filename) : $phpbb_root_path . $config['upload_path'] . '/' . basename($filename); + return @unlink($filename); } // All-encompasing sync function |