Comparing version 0.2.2 to 0.2.3
{ | ||
"name": "escomplex", | ||
"version": "0.2.2", | ||
"version": "0.2.3", | ||
"description": "Software complexity analysis of JavaScript-family abstract syntax trees.", | ||
@@ -5,0 +5,0 @@ "homepage": "https://github.com/philbooth/escomplex", |
@@ -320,10 +320,10 @@ /*globals exports, require */ | ||
if (averageEffort === 0 || averageLoc === 0) { | ||
report.maintainability = | ||
171 - | ||
(3.42 * Math.log(averageEffort)) - | ||
(0.23 * Math.log(averageCyclomatic)) - | ||
(16.2 * Math.log(averageLoc)); | ||
if (report.maintainability > 171) { | ||
report.maintainability = 171; | ||
} else { | ||
report.maintainability = | ||
171 - | ||
(3.42 * Math.log(averageEffort)) - | ||
(0.23 * Math.log(averageCyclomatic)) - | ||
(16.2 * Math.log(averageLoc)); | ||
} | ||
@@ -330,0 +330,0 @@ |
Sorry, the diff of this file is too big to display
169588
3262