From 5dc1fb5b0e4ceff6be378aaf88b71f3b577cae0d Mon Sep 17 00:00:00 2001 From: Robert Jaros Date: Tue, 9 Jul 2019 21:23:56 +0200 Subject: Fix tests. --- src/main/kotlin/pl/treksoft/kvision/utils/Snabbdom.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/main/kotlin/pl/treksoft/kvision') diff --git a/src/main/kotlin/pl/treksoft/kvision/utils/Snabbdom.kt b/src/main/kotlin/pl/treksoft/kvision/utils/Snabbdom.kt index db40c072..583dd74c 100644 --- a/src/main/kotlin/pl/treksoft/kvision/utils/Snabbdom.kt +++ b/src/main/kotlin/pl/treksoft/kvision/utils/Snabbdom.kt @@ -53,7 +53,7 @@ inline fun obj(init: dynamic.() -> Unit): dynamic { @Suppress("UNUSED_VARIABLE") inline fun Any?.createInstance(vararg args: dynamic): T { val jsClass = this - val argsArray = (listOf() + args).toTypedArray() + val argsArray = (listOf(null) + args).toTypedArray() return js("new (Function.prototype.bind.apply(jsClass, argsArray))").unsafeCast() } -- cgit