#6259: Files not moving when destination folder already exists ---------------------------+------------------------------------------------ Reporter: brezee | Type: Bug Status: new | Priority: Medium Milestone: 1.2.x.x | Component: General Version: 1.2 Final | Severity: Normal Keywords: move files | Php_version: PHP 5 Cake_version: | ---------------------------+------------------------------------------------ Bug exist on file /cake/libs/folder.php When I try use method move and destination folder already exist this method moved only top level of files, but files on sub folder not copies.
I look folder.php , method move use 2 other method copy and delete. I think bug on string 605 (method copy), please look (strings 605 - 618) : {{{ if (is_dir($from) && !file_exists($to)) { $old = umask(0); if (mkdir($to, $mode)) { umask($old); $old = umask(0); chmod($to, $mode); umask($old); $this->__messages[] = sprintf(__('%s created', true), $to); $options = array_merge($options, array('to'=> $to, 'from'=> $from)); $this->copy($options); } else { $this->__errors[] = sprintf(__('%s not created', true), $to); } } }}} In condition {{{ if (is_dir($from) && !file_exists($to)) }}} we verify if exist destination folder, if no we create folder and copy files, but if folder already exist we nothing to do ? -- Ticket URL: <https://trac.cakephp.org/ticket/6259> CakePHP : The Rapid Development Framework for PHP <https://trac.cakephp.org/> Cake is a rapid development framework for PHP which uses commonly known design patterns like ActiveRecord, Association Data Mapping, Front Controller and MVC. Our primary goal is to provide a structured framework that enables PHP users at all levels to rapidly develop robust web applications, without any loss to flexibility. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "tickets cakephp" group. To post to this group, send email to tickets-cakephp@googlegroups.com To unsubscribe from this group, send email to tickets-cakephp+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/tickets-cakephp?hl=en -~----------~----~----~----~------~----~------~--~---