Skip to content

[CLEANUP] Rector: Add strict return type based native function or class method return #602

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jun 21, 2024
Merged
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
8 changes: 2 additions & 6 deletions src/OutputFormatter.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,8 @@ public function __construct(OutputFormat $oFormat)
/**
* @param string $sName
* @param string|null $sType
*
* @return string
*/
public function space($sName, $sType = null)
public function space($sName, $sType = null): string
{
$sSpaceString = $this->oFormat->get("Space$sName");
// If $sSpaceString is an array, we have multiple values configured
Expand Down Expand Up @@ -235,10 +233,8 @@ public function comments(Commentable $oCommentable): string

/**
* @param string $sSpaceString
*
* @return string
*/
private function prepareSpace($sSpaceString)
private function prepareSpace($sSpaceString): string
{
return str_replace("\n", "\n" . $this->indent(), $sSpaceString);
}
Expand Down