We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 46e4b47 commit 153818dCopy full SHA for 153818d
2 files changed
module-extkt-json/src/commonMain/kotlin/JsonArrayLike.kt
@@ -23,7 +23,7 @@ import kotlinx.serialization.json.JsonPrimitive
23
24
/** return a copy of [this] with [block] applied to it. */
25
fun JsonArrayLike.copy(block: MutableJsonArrayLike.() -> Unit): JsonArray {
26
- return JsonArray(buildList { addAll(this); block() })
+ return JsonArray(buildList { addAll(this@copy); block() })
27
}
28
29
//
module-extkt-json/src/commonMain/kotlin/JsonObjectLike.kt
@@ -24,7 +24,7 @@ import kotlin.jvm.JvmName
fun JsonObjectLike.copy(block: MutableJsonObjectLike.() -> Unit): JsonObject {
- return JsonObject(buildMap { putAll(this); block() })
+ return JsonObject(buildMap { putAll(this@copy); block() })
30
0 commit comments