Code cleanup: x as? Type ?: return -> if (x !is Type) return

This commit is contained in:
Mikhail Glukhikh
2018-08-30 19:10:36 +03:00
parent ad4da3d761
commit ccb17caf7b
7 changed files with 8 additions and 8 deletions
@@ -52,7 +52,7 @@ val PersistentLibraryKind<*>?.platform: TargetPlatform
}
fun getLibraryPlatform(project: Project, library: Library): TargetPlatform {
library as? LibraryEx ?: return JvmPlatform
if (library !is LibraryEx) return JvmPlatform
if (library.isDisposed) return JvmPlatform
return library.effectiveKind(project).platform