@@ -104,8 +104,7 @@ |
||
| 104 | 104 | $connection->executeUpdate($query); |
| 105 | 105 | $query = "CREATE USER '$name'@'%' IDENTIFIED BY '$password'"; |
| 106 | 106 | $connection->executeUpdate($query); |
| 107 | - } |
|
| 108 | - catch (\Exception $ex){ |
|
| 107 | + } catch (\Exception $ex){ |
|
| 109 | 108 | $this->logger->logException($ex, [ |
| 110 | 109 | 'message' => 'Database user creation failed.', |
| 111 | 110 | 'level' => ILogger::ERROR, |
@@ -47,7 +47,7 @@ discard block |
||
| 47 | 47 | $this->path=$source; |
| 48 | 48 | $this->zip=new \ZipArchive(); |
| 49 | 49 | if($this->zip->open($source, \ZipArchive::CREATE)) { |
| 50 | - }else{ |
|
| 50 | + } else{ |
|
| 51 | 51 | \OCP\Util::writeLog('files_archive', 'Error while opening archive '.$source, ILogger::WARN); |
| 52 | 52 | } |
| 53 | 53 | } |
@@ -68,7 +68,7 @@ discard block |
||
| 68 | 68 | public function addFile($path, $source='') { |
| 69 | 69 | if($source and $source[0]=='/' and file_exists($source)) { |
| 70 | 70 | $result=$this->zip->addFile($source, $path); |
| 71 | - }else{ |
|
| 71 | + } else{ |
|
| 72 | 72 | $result=$this->zip->addFromString($path, $source); |
| 73 | 73 | } |
| 74 | 74 | if($result) { |
@@ -177,7 +177,7 @@ discard block |
||
| 177 | 177 | public function remove($path) { |
| 178 | 178 | if($this->fileExists($path.'/')) { |
| 179 | 179 | return $this->zip->deleteName($path.'/'); |
| 180 | - }else{ |
|
| 180 | + } else{ |
|
| 181 | 181 | return $this->zip->deleteName($path); |
| 182 | 182 | } |
| 183 | 183 | } |
@@ -196,7 +196,7 @@ discard block |
||
| 196 | 196 | //in the archive when the stream is closed |
| 197 | 197 | if(strrpos($path, '.')!==false) { |
| 198 | 198 | $ext=substr($path, strrpos($path, '.')); |
| 199 | - }else{ |
|
| 199 | + } else{ |
|
| 200 | 200 | $ext=''; |
| 201 | 201 | } |
| 202 | 202 | $tmpFile = \OC::$server->getTempManager()->getTemporaryFile($ext); |
@@ -225,7 +225,7 @@ discard block |
||
| 225 | 225 | private function stripPath($path) { |
| 226 | 226 | if(!$path || $path[0]=='/') { |
| 227 | 227 | return substr($path, 1); |
| 228 | - }else{ |
|
| 228 | + } else{ |
|
| 229 | 229 | return $path; |
| 230 | 230 | } |
| 231 | 231 | } |
@@ -459,7 +459,7 @@ |
||
| 459 | 459 | $appDir = OC_App::getInstallPath() . '/' . $appId; |
| 460 | 460 | OC_Helper::rmdirr($appDir); |
| 461 | 461 | return true; |
| 462 | - }else{ |
|
| 462 | + } else{ |
|
| 463 | 463 | \OCP\Util::writeLog('core', 'can\'t remove app '.$appId.'. It is not installed.', ILogger::ERROR); |
| 464 | 464 | |
| 465 | 465 | return false; |