diff --git a/diktat-rules/src/main/kotlin/org/cqfn/diktat/ruleset/rules/TypeAliasRule.kt b/diktat-rules/src/main/kotlin/org/cqfn/diktat/ruleset/rules/TypeAliasRule.kt index f7c6c7edfc..2abc7e1709 100644 --- a/diktat-rules/src/main/kotlin/org/cqfn/diktat/ruleset/rules/TypeAliasRule.kt +++ b/diktat-rules/src/main/kotlin/org/cqfn/diktat/ruleset/rules/TypeAliasRule.kt @@ -36,7 +36,7 @@ class TypeAliasRule(private val configRules: List) : Rule("type-ali if (node.elementType == TYPE_REFERENCE && node .parents() .map { it.elementType } - .none { it == SUPER_TYPE_LIST || it == TYPEALIAS}) { + .none { it == SUPER_TYPE_LIST || it == TYPEALIAS }) { checkTypeReference(node, TypeAliasConfiguration(configRules.getRuleConfig(TYPE_ALIAS)?.configuration ?: emptyMap())) } } diff --git a/diktat-rules/src/main/kotlin/org/cqfn/diktat/ruleset/rules/UselessSupertype.kt b/diktat-rules/src/main/kotlin/org/cqfn/diktat/ruleset/rules/UselessSupertype.kt index 7c0ef69d93..598f963bb0 100644 --- a/diktat-rules/src/main/kotlin/org/cqfn/diktat/ruleset/rules/UselessSupertype.kt +++ b/diktat-rules/src/main/kotlin/org/cqfn/diktat/ruleset/rules/UselessSupertype.kt @@ -139,7 +139,7 @@ class UselessSupertype(private val configRules: List) : Rule("usele it.getIdentifierName()!!.text in methodsName } overrideFunctions.forEach { - functionNameMap.compute(it.getIdentifierName()!!.text) { _, oldValue -> (oldValue ?: 0) + 1} + functionNameMap.compute(it.getIdentifierName()!!.text) { _, oldValue -> (oldValue ?: 0) + 1 } } } return functionNameMap.toMap() diff --git a/diktat-rules/src/main/kotlin/org/cqfn/diktat/ruleset/utils/KotlinParser.kt b/diktat-rules/src/main/kotlin/org/cqfn/diktat/ruleset/utils/KotlinParser.kt index 8243f21656..d5e0cbc0a6 100644 --- a/diktat-rules/src/main/kotlin/org/cqfn/diktat/ruleset/utils/KotlinParser.kt +++ b/diktat-rules/src/main/kotlin/org/cqfn/diktat/ruleset/utils/KotlinParser.kt @@ -50,7 +50,7 @@ class KotlinParser { } } // I don't really understand what's going on here, but thanks to this, you can use this node in the future val project = KotlinCoreEnvironment.createForProduction( - Disposable {}, + Disposable { }, compilerConfiguration, EnvironmentConfigFiles.JVM_CONFIG_FILES ).project // create project