Skip to content

Commit f6c5852

Browse files
committed
S48-945: Add Plugin/Observer class complexity rule
- fine tuning thresholds
1 parent f7dfc56 commit f6c5852

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

rulesets/PhpMd/Magento/EntryPointClassComplexity.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ private function applyForMethod(AbstractNode $node, string $thresholdProperty, s
4949
$node->getType(),
5050
$node->getName(),
5151
$ccn,
52-
$threshold,
52+
$threshold + 1,
5353
$methodType
5454
)
5555
);

rulesets/PhpMd/extra.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ method entry. The decision points are 'if', 'while', 'for', and 'case labels'. G
8686
<priority>3</priority>
8787
<properties>
8888
<property name="reportLevel" description="The Cyclomatic Complexity reporting threshold for plugin and observer public methods" value="6"/>
89-
<property name="reportLevelPrivate" description="The Cyclomatic Complexity reporting threshold for private methods" value="3"/>
89+
<property name="reportLevelPrivate" description="The Cyclomatic Complexity reporting threshold for private methods" value="4"/>
9090
<property name="showClassesComplexity"
9191
description="Indicate if class average violation should be added to the report"
9292
value="true"/>

0 commit comments

Comments
 (0)