mirror of
https://github.com/szkolny-eu/szkolny-android.git
synced 2024-11-24 10:54:36 -06:00
[API/Vulcan] Fix wrong serializing of null in JSON causing API error.
This commit is contained in:
parent
5007587192
commit
5f8016061d
@ -73,7 +73,8 @@ fun JsonObject(vararg properties: Pair<String, Any?>): JsonObject {
|
|||||||
is Number -> addProperty(key, value)
|
is Number -> addProperty(key, value)
|
||||||
is Boolean -> addProperty(key, value)
|
is Boolean -> addProperty(key, value)
|
||||||
is Enum<*> -> addProperty(key, value.toInt())
|
is Enum<*> -> addProperty(key, value.toInt())
|
||||||
else -> add(key, property.toJsonElement())
|
null -> add(key, null)
|
||||||
|
else -> add(key, value.toJsonElement())
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user