From 7909b729bbb1facce975b10da28754eb157723aa Mon Sep 17 00:00:00 2001 From: Jim Wigginton Date: Sun, 12 Jul 2009 15:44:43 +0000 Subject: unified the transfer routines from the updater and from acp_language.php. still needs work.. git-svn-id: file:///svn/phpbb/trunk@9751 89ea8834-ac86-4346-8a33-228a782c2dd0 --- phpBB/includes/functions_transfer.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'phpBB/includes/functions_transfer.php') diff --git a/phpBB/includes/functions_transfer.php b/phpBB/includes/functions_transfer.php index a276bd304a..351f9517c5 100644 --- a/phpBB/includes/functions_transfer.php +++ b/phpBB/includes/functions_transfer.php @@ -16,7 +16,7 @@ if (!defined('IN_PHPBB')) exit; } -require_once PHPBB_ROOT_PATH . 'includes/sftp/sftp.' . PHP_EXT; +require_once PHPBB_ROOT_PATH . 'includes/libraries/sftp/sftp.' . PHP_EXT; /** * Transfer class, wrapper for ftp/sftp/ssh @@ -192,7 +192,7 @@ class transfer $directory = $this->root_path . str_replace(PHPBB_ROOT_PATH, '', $directory); $this->_chdir($directory); - $result = $this->_ls(); + $result = $this->_ls(''); if ($result !== false && is_array($result)) { @@ -455,7 +455,7 @@ class ftp extends transfer $item = str_replace('\\', '/', $item); $dir = str_replace('\\', '/', $dir); - if (strpos($item, $dir) === 0) + if (!empty($dir) && strpos($item, $dir) === 0) { $item = substr($item, strlen($dir)); } -- cgit v1.2.1