File tree Expand file tree Collapse file tree 3 files changed +3
-3
lines changed
androidMain/kotlin/dev/gitlive/firebase
iosMain/kotlin/dev/gitlive/firebase
jsMain/kotlin/dev/gitlive/firebase Expand file tree Collapse file tree 3 files changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -20,7 +20,7 @@ actual fun FirebaseDecoder.structureDecoder(descriptor: SerialDescriptor): Compo
2020 }
2121 }
2222 }
23- StructureKind .LIST -> (value as List <* >).let {
23+ StructureKind .LIST -> ((value as ? Map < * , * >)?.values?.toList() ? : value as List <* >).let {
2424 FirebaseCompositeDecoder (it.size) { _, index -> it[index] }
2525 }
2626 StructureKind .MAP -> (value as Map <* , * >).entries.toList().let {
Original file line number Diff line number Diff line change @@ -20,7 +20,7 @@ actual fun FirebaseDecoder.structureDecoder(descriptor: SerialDescriptor): Compo
2020 }
2121 }
2222 }
23- StructureKind .LIST -> (value as List <* >).let {
23+ StructureKind .LIST -> ((value as ? Map < * , * >)?.values?.toList() ? : value as List <* >).let {
2424 FirebaseCompositeDecoder (it.size) { _, index -> it[index] }
2525 }
2626 StructureKind .MAP -> (value as Map <* , * >).entries.toList().let {
Original file line number Diff line number Diff line change @@ -22,7 +22,7 @@ actual fun FirebaseDecoder.structureDecoder(descriptor: SerialDescriptor): Compo
2222 }
2323 }
2424 }
25- StructureKind .LIST -> (value as Array <* >).let {
25+ StructureKind .LIST -> (js( " Object " ).values( value) as Array <* >).let {
2626 FirebaseCompositeDecoder (it.size) { _, index -> it[index] }
2727 }
2828 StructureKind .MAP -> (js(" Object" ).entries(value) as Array <Array <Any >>).let {
You can’t perform that action at this time.
0 commit comments