From 57da0d71e37adebb72d90292f850c06d4d969547 Mon Sep 17 00:00:00 2001 From: Robert Jaros Date: Tue, 27 Feb 2018 09:33:07 +0100 Subject: Various fixes for window component. --- src/main/kotlin/pl/treksoft/kvision/KVManager.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/main/kotlin/pl/treksoft/kvision/KVManager.kt') diff --git a/src/main/kotlin/pl/treksoft/kvision/KVManager.kt b/src/main/kotlin/pl/treksoft/kvision/KVManager.kt index 4ab7c1d0..ab4f7e13 100644 --- a/src/main/kotlin/pl/treksoft/kvision/KVManager.kt +++ b/src/main/kotlin/pl/treksoft/kvision/KVManager.kt @@ -143,7 +143,7 @@ internal object KVManager { @Suppress("UnsafeCastFromDynamic") internal fun clearResizeEvent(component: Component) { - if (component.getElement().asDynamic().__resizeTrigger__.contentDocument != null) { + if (component.getElement()?.asDynamic()?.__resizeTrigger__?.contentDocument != null) { component.getElement()?.let { elementResizeEvent.unbind(it) } -- cgit