Skip to content
This repository was archived by the owner on Jul 8, 2020. It is now read-only.

example(test): Add some errors to the code #21

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions action/src/Actions/CreateReview.php
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ class CreateReview implements Action

public function __construct(GitHubContext $context, GitHubReviewFormatter $formatter, Configuration $configuration)
{
$this->client = $context->getGitHubClient('comfort-fade-preview');
$this->client = $context->getGitHubClient("comfort-fade-preview");
$this->githubContext = $context;
$this->formatter = $formatter;
$this->configuration = $configuration;
Expand Down Expand Up @@ -223,7 +223,8 @@ private static function getDescription(Results $results, string $reviewStatus, i
if ($reviewStatus === Review::COMMENT) {
return "{$prepend}PHP Insights has some concerns, please look into it.\n{$table}";
}

return "{$prepend}PHP Insights is not happy, please look into the comments, so we can be friends again.\n{$table}";
else {

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[No else] Do not use "else/elseif". Prefer early return statement instead.

return "{$prepend}PHP Insights is not happy, please look into the comments, so we can be friends again.\n{$table}";

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[Line length] Line exceeds maximum limit of 120 characters; contains 127 characters

}
}
}