/** * Copy file into another file * * @param string $source source file path * @param string $targetDir target directory path * @param string $name new file name * @return bool * @author Dmitry (dio) Levashov **/ protected function _copy($source, $targetDir, $name) { $path = $this->_normpath($targetDir . '/' . $name); try { $this->dropbox->copy($source, $path); } catch (Dropbox_Exception $e) { return $this->setError('Dropbox error: ' . $e->getMessage()); } $this->deltaCheck(); return true; }