@@ -34,9 +34,9 @@ discard block |
||
34 | 34 | { |
35 | 35 | C::assertTrue(function_exists('ftp_connect'), '请开启 ftp 扩展'); |
36 | 36 | C::assertTrue(Arrays::keyExistsAll(['host', 'username', 'password'], $config, $diff), '缺少 ' . implode(',', $diff) . ' 参数'); |
37 | - $this->_conn = ftp_connect((string) I::get($config, 'host'), (int) I::get($config, 'port', 21), (int) I::get($config, 'timeout', 90)); |
|
37 | + $this->_conn = ftp_connect((string)I::get($config, 'host'), (int)I::get($config, 'port', 21), (int)I::get($config, 'timeout', 90)); |
|
38 | 38 | C::assertTrue(is_resource($this->_conn), '连接失败'); |
39 | - C::assertTrue(@ftp_login($this->_conn, (string) I::get($config, 'username'), (string) I::get($config, 'password')), '账号密码错误'); |
|
39 | + C::assertTrue(@ftp_login($this->_conn, (string)I::get($config, 'username'), (string)I::get($config, 'password')), '账号密码错误'); |
|
40 | 40 | ftp_pasv($this->_conn, true); |
41 | 41 | } |
42 | 42 | |
@@ -194,7 +194,7 @@ discard block |
||
194 | 194 | /** @scrutinizer ignore-unhandled */@ftp_chmod($this->_conn, $mode, $subFile); |
195 | 195 | } |
196 | 196 | } |
197 | - return (bool) /** @scrutinizer ignore-unhandled */@ftp_chmod($this->_conn, $mode, $file); |
|
197 | + return (bool)/** @scrutinizer ignore-unhandled */@ftp_chmod($this->_conn, $mode, $file); |
|
198 | 198 | } |
199 | 199 | |
200 | 200 | /** |
@@ -239,7 +239,7 @@ discard block |
||
239 | 239 | */ |
240 | 240 | protected function _mkdir($dir, $mode = 0777) |
241 | 241 | { |
242 | - $isCreated = (bool) @ftp_mkdir($this->_conn, $dir); |
|
242 | + $isCreated = (bool)@ftp_mkdir($this->_conn, $dir); |
|
243 | 243 | $this->chmod($dir, $mode, FileConstants::RECURSIVE_DISABLED); |
244 | 244 | return $isCreated; |
245 | 245 | } |