summaryrefslogtreecommitdiffstats
path: root/wp-includes/cache.php
diff options
context:
space:
mode:
Diffstat (limited to 'wp-includes/cache.php')
-rw-r--r--wp-includes/cache.php5
1 files changed, 2 insertions, 3 deletions
diff --git a/wp-includes/cache.php b/wp-includes/cache.php
index e89e5f6..6901a6b 100644
--- a/wp-includes/cache.php
+++ b/wp-includes/cache.php
@@ -364,10 +364,9 @@ class WP_Object_Cache {
fputs($fd, $serial);
fclose($fd);
if (!@ rename($temp_file, $cache_file)) {
- if (@ copy($temp_file, $cache_file))
- @ unlink($temp_file);
- else
+ if (!@ copy($temp_file, $cache_file))
$errors++;
+ @ unlink($temp_file);
}
@ chmod($cache_file, $file_perms);
}