aboutsummaryrefslogtreecommitdiff
path: root/src/phorkie/Tools.php
diff options
context:
space:
mode:
authorChristian Weiske <cweiske@cweiske.de>2012-09-28 12:58:39 +0200
committerChristian Weiske <cweiske@cweiske.de>2012-09-28 12:58:39 +0200
commit6bde4b82ec04ee5a1622220663bcacca2ec301d6 (patch)
tree765e9ea621686473b77eea6c957b9d70d6bffc96 /src/phorkie/Tools.php
parent56bf0267e1e3218e22992a25927a10e754bf71f3 (diff)
downloadphorkie-6bde4b82ec04ee5a1622220663bcacca2ec301d6.tar.gz
phorkie-6bde4b82ec04ee5a1622220663bcacca2ec301d6.zip
do not try to delete if file does not exist
Diffstat (limited to 'src/phorkie/Tools.php')
-rw-r--r--src/phorkie/Tools.php3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/phorkie/Tools.php b/src/phorkie/Tools.php
index 9435dc0..1d3d226 100644
--- a/src/phorkie/Tools.php
+++ b/src/phorkie/Tools.php
@@ -13,6 +13,9 @@ class Tools
*/
public static function recursiveDelete($path)
{
+ if (!file_exists($path)) {
+ return true;
+ }
if (!is_dir($path) || is_link($path)) {
return unlink($path);
}