Ticket #12150: rename-2.patch
| File rename-2.patch, 682 bytes (added by reaperhulk, 3 years ago) |
|---|
-
class-wp-filesystem-direct.php
205 205 } 206 206 207 207 function move($source, $destination, $overwrite = false) { 208 //Possible to use rename()? 208 if ( ! $overwrite && $this->exists($destination) ) 209 return false; 210 211 //try using rename first. if that fails (for example, source is read only) try copy 212 if (@rename($source, $destination)) 213 return true; 214 209 215 if ( $this->copy($source, $destination, $overwrite) && $this->exists($destination) ) { 210 216 $this->delete($source); 211 217 return true;
