Skip to content

Commit 0269f90

Browse files
committed
🐛 Fix a spelling mistake in the Max line per method rule
1 parent bb20642 commit 0269f90

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/Rules/MaxLinePerMethodRule.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ public function processNode(Node $node, Scope $scope): array
2828
return [
2929
RuleErrorBuilder::message(
3030
sprintf(
31-
'The %s function has more than %d code lines. Please reduce it. The recommended class length is %d lines.',
31+
'The %s function has more than %d code lines. Please reduce it. The recommended method length is %d lines.',
3232
$node->name->toString(),
3333
self::MAX_LINES,
3434
self::RECOMMENDED_LINES

tests/Rules/MaxLinePerMethodRuleTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ public function testWithMultipleLines(): void
2323
// each error consists of the asserted error message, and the asserted error file line
2424
$this->analyse([__DIR__ . '/data/MaxLinePerMethodRule/MultipleLinesMethods.php'], [
2525
[
26-
"The fortyOneLines function has more than 40 code lines. Please reduce it. The recommended class length is 20 lines.", // asserted error message
26+
"The fortyOneLines function has more than 40 code lines. Please reduce it. The recommended method length is 20 lines.", // asserted error message
2727
93, // asserted error line
2828
],
2929
]);

0 commit comments

Comments
 (0)