diff options
-rw-r--r-- | lib/mailtemplate.php | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/lib/mailtemplate.php b/lib/mailtemplate.php index c1c1b84..285aa83 100644 --- a/lib/mailtemplate.php +++ b/lib/mailtemplate.php @@ -124,8 +124,10 @@ class MailTemplate extends \OC_Template { if (rename($absolutePath.'.bak', $absolutePath)) { return true; } - } else if (unlink($absolutePath)) { - return true; + } else if(file_exists($absolutePath)) { + if (unlink($absolutePath)) { + return true; + } } } return !file_exists($absolutePath); |