aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--kvision-modules/kvision-tabulator-remote/src/main/kotlin/pl/treksoft/kvision/tabulator/TabulatorRemote.kt4
1 files changed, 2 insertions, 2 deletions
diff --git a/kvision-modules/kvision-tabulator-remote/src/main/kotlin/pl/treksoft/kvision/tabulator/TabulatorRemote.kt b/kvision-modules/kvision-tabulator-remote/src/main/kotlin/pl/treksoft/kvision/tabulator/TabulatorRemote.kt
index 21bfc5d4..7e2b533e 100644
--- a/kvision-modules/kvision-tabulator-remote/src/main/kotlin/pl/treksoft/kvision/tabulator/TabulatorRemote.kt
+++ b/kvision-modules/kvision-tabulator-remote/src/main/kotlin/pl/treksoft/kvision/tabulator/TabulatorRemote.kt
@@ -73,8 +73,8 @@ open class TabulatorRemote<T : Any, E : Any>(
val callAgent = CallAgent()
@Suppress("UnsafeCastFromDynamic")
- val beforeSend: ((JQueryXHR, JQueryAjaxSettings) -> Boolean)? = options.ajaxConfig.beforeSend
- options.ajaxConfig.beforeSend = undefined
+ val beforeSend: ((JQueryXHR, JQueryAjaxSettings) -> Boolean)? = options.ajaxConfig?.beforeSend
+ if (beforeSend != null) options.ajaxConfig.beforeSend = undefined
options.ajaxURL = urlPrefix + url.drop(1)
options.ajaxRequestFunc = { _, _, params ->
val page = params.page