phpinsights icon indicating copy to clipboard operation
phpinsights copied to clipboard

use config for calculating complexity

Open damek24 opened this issue 1 year ago • 0 comments

Q A
Bug fix? yes
New feature? no

Previously configuration value for max allowed complexity was only used for reporting errors. For calculating complexity percentage 1 was always used as max allowed complexity. As a result when setting this config value to any number higher than 1 and having any class with complexity higher than 1 disallowed to have complexity percentage at level 100%. This PR fixes this - for now config value for max allowed complexity is both used for percentage calculations and for error reporting

damek24 avatar Apr 05 '24 13:04 damek24