diff options
Diffstat (limited to 'apps/files_external')
-rw-r--r-- | apps/files_external/lib/amazons3.php | 2 | ||||
-rwxr-xr-x | apps/files_external/lib/config.php | 12 | ||||
-rw-r--r-- | apps/files_external/lib/sftp.php | 2 |
3 files changed, 8 insertions, 8 deletions
diff --git a/apps/files_external/lib/amazons3.php b/apps/files_external/lib/amazons3.php index f4d1940b184..9363a350e27 100644 --- a/apps/files_external/lib/amazons3.php +++ b/apps/files_external/lib/amazons3.php @@ -79,7 +79,7 @@ class AmazonS3 extends \OC\Files\Storage\Common { $this->bucket = $params['bucket']; $scheme = ($params['use_ssl'] === 'false') ? 'http' : 'https'; - $this->test = ( isset($params['test'])) ? true : false; + $this->test = isset($params['test']); $this->timeout = ( ! isset($params['timeout'])) ? 15 : $params['timeout']; $params['region'] = ( ! isset($params['region'])) ? 'eu-west-1' : $params['region']; $params['hostname'] = ( !isset($params['hostname'])) ? 's3.amazonaws.com' : $params['hostname']; diff --git a/apps/files_external/lib/config.php b/apps/files_external/lib/config.php index 14e974d65ca..1935740cd2e 100755 --- a/apps/files_external/lib/config.php +++ b/apps/files_external/lib/config.php @@ -418,9 +418,9 @@ class OC_Mount_Config { public static function checksmbclient() { if(function_exists('shell_exec')) { $output=shell_exec('which smbclient'); - return (empty($output)?false:true); + return !empty($output); }else{ - return(false); + return false; } } @@ -429,9 +429,9 @@ class OC_Mount_Config { */ public static function checkphpftp() { if(function_exists('ftp_login')) { - return(true); + return true; }else{ - return(false); + return false; } } @@ -439,7 +439,7 @@ class OC_Mount_Config { * check if curl is installed */ public static function checkcurl() { - return (function_exists('curl_init')); + return function_exists('curl_init'); } /** @@ -460,6 +460,6 @@ class OC_Mount_Config { $txt.=$l->t('<b>Warning:</b> The Curl support in PHP is not enabled or installed. Mounting of ownCloud / WebDAV or GoogleDrive is not possible. Please ask your system administrator to install it.').'<br />'; } - return($txt); + return $txt; } } diff --git a/apps/files_external/lib/sftp.php b/apps/files_external/lib/sftp.php index 4fd36096463..f7f329b8993 100644 --- a/apps/files_external/lib/sftp.php +++ b/apps/files_external/lib/sftp.php @@ -170,7 +170,7 @@ class SFTP extends \OC\Files\Storage\Common { public function file_exists($path) { try { - return $this->client->stat($this->abs_path($path)) === false ? false : true; + return $this->client->stat($this->abs_path($path)) !== false; } catch (\Exception $e) { return false; } |