Added option to do data and attachment directory hashing, up to four levels. Will...
[squirrelmail.git] / src / signout.php
index ed82aeb2e5223fa8bce9e941919d3d3b06befcab..8e15b7c83d7ad3b060241d11f16fd4e59f85d85c 100644 (file)
@@ -35,9 +35,11 @@ require_once('../functions/plugin.php');
    if (! isset($attachments)) {
        $attachments = array();
    }
+   $hashed_attachment_dir = getHashedDir($username, $attachment_dir);
    foreach ($attachments as $info) {
-       if (file_exists($attachment_dir . $info['localfilename'])) {
-           unlink($attachment_dir . $info['localfilename']);
+       $attached_file = "$hashed_attachment_dir/$info[localfilename]";
+       if (file_exists($attached_file)) {
+           unlink($attached_file);
        }
    }