Code cleanup: replace chained null-checks with safe-calls
This commit is contained in:
committed by
Mikhail Glukhikh
parent
732d1129ab
commit
7fb78a0372
@@ -116,7 +116,7 @@ abstract class KotlinCommonBlock(
|
||||
val childParent = child.treeParent
|
||||
val childType = child.elementType
|
||||
|
||||
if (childParent != null && childParent.treeParent != null) {
|
||||
if (childParent?.treeParent != null) {
|
||||
if (childParent.elementType === KtNodeTypes.BLOCK && childParent.treeParent.elementType === KtNodeTypes.SCRIPT) {
|
||||
return Indent.getNoneIndent()
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user