Skip to content

Commit

Permalink
Suppress buggy code style check for parameter attributes
Browse files Browse the repository at this point in the history
Signed-off-by: Tim Düsterhus <[email protected]>
  • Loading branch information
TimWolla committed Dec 13, 2022
1 parent 506e992 commit 278c5db
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/CreditCard.php
Original file line number Diff line number Diff line change
Expand Up @@ -356,6 +356,9 @@ public function setService($service)
return $this;
}

// The following rule is buggy for parameters attributes
// phpcs:disable SlevomatCodingStandard.TypeHints.ParameterTypeHintSpacing.NoSpaceBetweenTypeHintAndParameter

/**
* Returns true if and only if $value follows the Luhn algorithm (mod-10 checksum)
*
Expand Down Expand Up @@ -436,4 +439,6 @@ public function isValid(

return true;
}

// phpcs:enable SlevomatCodingStandard.TypeHints.ParameterTypeHintSpacing.NoSpaceBetweenTypeHintAndParameter
}
5 changes: 5 additions & 0 deletions src/UndisclosedPassword.php
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,9 @@ public function __construct(private ClientInterface $httpClient, private Request
parent::__construct();
}

// The following rule is buggy for parameters attributes
// phpcs:disable SlevomatCodingStandard.TypeHints.ParameterTypeHintSpacing.NoSpaceBetweenTypeHintAndParameter

/** {@inheritDoc} */
public function isValid(
#[SensitiveParameter]
Expand All @@ -64,6 +67,8 @@ public function isValid(
return true;
}

// phpcs:enable SlevomatCodingStandard.TypeHints.ParameterTypeHintSpacing.NoSpaceBetweenTypeHintAndParameter

private function isPwnedPassword(
#[SensitiveParameter]
string $password
Expand Down

0 comments on commit 278c5db

Please sign in to comment.