@@ -235,7 +235,7 @@ |
||
| 235 | 235 | * Returns the user id of the committer. |
| 236 | 236 | * |
| 237 | 237 | * @param Project $project |
| 238 | - * @param $commitRef |
|
| 238 | + * @param string $commitRef |
|
| 239 | 239 | * @return int|null |
| 240 | 240 | */ |
| 241 | 241 | private function getCommiterId(Project $project, $commitRef) |
@@ -243,7 +243,7 @@ discard block |
||
| 243 | 243 | |
| 244 | 244 | $commit = $project->commit($commitRef); |
| 245 | 245 | |
| 246 | - return $commit->committer ? $commit->committer->id : null; |
|
| 246 | + return $commit->committer ? $commit->committer->id : null; |
|
| 247 | 247 | } |
| 248 | 248 | |
| 249 | 249 | /** |
@@ -261,7 +261,7 @@ discard block |
||
| 261 | 261 | |
| 262 | 262 | $buildService->dumpArtifactFromBranch($projectName, $targetBranch, $jobStage, $tmpFile); |
| 263 | 263 | $zipFile = new \ZipArchive(); |
| 264 | - if ($zipFile->open($tmpFile)!==true) { |
|
| 264 | + if ($zipFile->open($tmpFile) !== true) { |
|
| 265 | 265 | throw new \RuntimeException('Invalid ZIP archive '.$tmpFile); |
| 266 | 266 | } |
| 267 | 267 | return $this->getMeasuresFromZipFile($zipFile, $cloverPath, $crap4JPath); |
@@ -285,7 +285,7 @@ discard block |
||
| 285 | 285 | $build = $buildService->getLatestBuildFromCommitId($projectName, $commitId); |
| 286 | 286 | $buildService->dumpArtifact($projectName, $build['id'], $jobStage, $tmpFile); |
| 287 | 287 | $zipFile = new \ZipArchive(); |
| 288 | - if ($zipFile->open($tmpFile)!==true) { |
|
| 288 | + if ($zipFile->open($tmpFile) !== true) { |
|
| 289 | 289 | throw new \RuntimeException('Invalid ZIP archive '.$tmpFile); |
| 290 | 290 | } |
| 291 | 291 | return $this->getMeasuresFromZipFile($zipFile, $cloverPath, $crap4JPath); |
@@ -53,9 +53,9 @@ |
||
| 53 | 53 | throw new \RuntimeException('Could not find the Gitlab URL in the "CI_REPOSITORY_URL" environment variable (usually set by Gitlab CI). Either set this environment variable or pass the URL via the --gitlab-url command line option.'); |
| 54 | 54 | } |
| 55 | 55 | $parsed_url = parse_url($ciProjectUrl); |
| 56 | - $scheme = isset($parsed_url['scheme']) ? $parsed_url['scheme'] . '://' : ''; |
|
| 56 | + $scheme = isset($parsed_url['scheme']) ? $parsed_url['scheme'].'://' : ''; |
|
| 57 | 57 | $host = isset($parsed_url['host']) ? $parsed_url['host'] : ''; |
| 58 | - $port = isset($parsed_url['port']) ? ':' . $parsed_url['port'] : ''; |
|
| 58 | + $port = isset($parsed_url['port']) ? ':'.$parsed_url['port'] : ''; |
|
| 59 | 59 | $gitlabUrl = $scheme.$host.$port; |
| 60 | 60 | } |
| 61 | 61 | return rtrim($gitlabUrl, '/'); |