SymbolTable: Rewrite nasty code with if without else in elvis RHS

This commit is contained in:
Mikhail Glukhikh
2021-02-11 08:40:32 +03:00
parent 4bc630d82c
commit 791f589127
@@ -192,9 +192,10 @@ class SymbolTable(
@OptIn(ObsoleteDescriptorBasedAPI::class)
override fun set(s: S) {
s.signature?.let {
idSigToSymbol[it] = s
} ?: if (s.hasDescriptor) {
val signature = s.signature
if (signature != null) {
idSigToSymbol[signature] = s
} else if (s.hasDescriptor) {
descriptorToSymbol[s.descriptor] = s
}
}