mirror of
https://github.com/szkolny-eu/szkolny-android.git
synced 2025-06-12 13:40:47 +02:00
[Extensions] Make asJsonObjectList return non-nullable JsonObjects.
This commit is contained in:
@ -95,7 +95,7 @@ operator fun Profile.set(key: String, value: String?) = this.studentData.addProp
|
|||||||
operator fun Profile.set(key: String, value: Number) = this.studentData.addProperty(key, value)
|
operator fun Profile.set(key: String, value: Number) = this.studentData.addProperty(key, value)
|
||||||
operator fun Profile.set(key: String, value: Char) = this.studentData.addProperty(key, value)
|
operator fun Profile.set(key: String, value: Char) = this.studentData.addProperty(key, value)
|
||||||
|
|
||||||
fun JsonArray.asJsonObjectList() = this.map { it.asJsonObject }
|
fun JsonArray.asJsonObjectList() = this.mapNotNull { it.asJsonObject }
|
||||||
|
|
||||||
fun CharSequence?.isNotNullNorEmpty(): Boolean {
|
fun CharSequence?.isNotNullNorEmpty(): Boolean {
|
||||||
return this != null && this.isNotEmpty()
|
return this != null && this.isNotEmpty()
|
||||||
|
Reference in New Issue
Block a user