Skip to content

Commit b56885e

Browse files
convert back to vararg
1 parent 2025ea8 commit b56885e

File tree

3 files changed

+8
-8
lines changed
  • firebase-firestore/src

3 files changed

+8
-8
lines changed

firebase-firestore/src/androidMain/kotlin/dev/gitlive/firebase/firestore/firestore.kt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -369,9 +369,9 @@ actual open class Query(open val android: com.google.firebase.firestore.Query) {
369369
internal actual fun _orderBy(field: FieldPath, direction: Direction) = Query(android.orderBy(field.android, direction))
370370

371371
internal actual fun _startAfter(document: DocumentSnapshot) = Query(android.startAfter(document.android))
372-
internal actual fun _startAfter(fieldValues: List<Any>) = Query(android.startAfter(*fieldValues.toTypedArray()))
372+
internal actual fun _startAfter(vararg fieldValues: Any) = Query(android.startAfter(*fieldValues))
373373
internal actual fun _startAt(document: DocumentSnapshot) = Query(android.startAt(document.android))
374-
internal actual fun _startAt(fieldValues: List<Any>) = Query(android.startAt(*fieldValues.toTypedArray()))
374+
internal actual fun _startAt(vararg fieldValues: Any) = Query(android.startAt(*fieldValues))
375375

376376
internal actual fun _endBefore(document: DocumentSnapshot) = Query(android.endBefore(document.android))
377377
internal actual fun _endBefore(vararg fieldValues: Any) = Query(android.endBefore(*fieldValues))

firebase-firestore/src/commonMain/kotlin/dev/gitlive/firebase/firestore/firestore.kt

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -70,9 +70,9 @@ expect open class Query {
7070
internal fun _orderBy(field: FieldPath, direction: Direction): Query
7171

7272
internal fun _startAfter(document: DocumentSnapshot): Query
73-
internal fun _startAfter(fieldValues: List<Any>): Query
73+
internal fun _startAfter(vararg fieldValues: Any): Query
7474
internal fun _startAt(document: DocumentSnapshot): Query
75-
internal fun _startAt(fieldValues: List<Any>): Query
75+
internal fun _startAt(vararg fieldValues: Any): Query
7676

7777
internal fun _endBefore(document: DocumentSnapshot): Query
7878
internal fun _endBefore(vararg fieldValues: Any): Query
@@ -93,9 +93,9 @@ fun Query.orderBy(field: String, direction: Direction = Direction.ASCENDING) = _
9393
fun Query.orderBy(field: FieldPath, direction: Direction = Direction.ASCENDING) = _orderBy(field, direction)
9494

9595
fun Query.startAfter(document: DocumentSnapshot) = _startAfter(document)
96-
fun Query.startAfter(fieldValues: List<Any>) = _startAfter(fieldValues)
96+
fun Query.startAfter(vararg fieldValues: Any) = _startAfter(fieldValues)
9797
fun Query.startAt(document: DocumentSnapshot) = _startAt(document)
98-
fun Query.startAt(fieldValues: List<Any>) = _startAt(fieldValues)
98+
fun Query.startAt(vararg fieldValues: Any) = _startAt(fieldValues)
9999

100100
fun Query.endBefore(document: DocumentSnapshot) = _endBefore(document)
101101
fun Query.endBefore(vararg fieldValues: Any) = _endBefore(fieldValues)

firebase-firestore/src/iosMain/kotlin/dev/gitlive/firebase/firestore/firestore.kt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -284,9 +284,9 @@ actual open class Query(open val ios: FIRQuery) {
284284
internal actual fun _orderBy(field: FieldPath, direction: Direction) = Query(ios.queryOrderedByFieldPath(field.ios, direction == Direction.DESCENDING))
285285

286286
internal actual fun _startAfter(document: DocumentSnapshot) = Query(ios.queryStartingAfterDocument(document.ios))
287-
internal actual fun _startAfter(fieldValues: List<Any>) = Query(ios.queryStartingAfterValues(fieldValues))
287+
internal actual fun _startAfter(vararg fieldValues: Any) = Query(ios.queryStartingAfterValues(fieldValues.asList()))
288288
internal actual fun _startAt(document: DocumentSnapshot) = Query(ios.queryStartingAtDocument(document.ios))
289-
internal actual fun _startAt(fieldValues: List<Any>) = Query(ios.queryStartingAtValues(fieldValues))
289+
internal actual fun _startAt(vararg fieldValues: Any) = Query(ios.queryStartingAtValues(fieldValues.asList()))
290290

291291
internal actual fun _endBefore(document: DocumentSnapshot) = Query(ios.queryEndingBeforeDocument(document.ios))
292292
internal actual fun _endBefore(vararg fieldValues: Any) = Query(ios.queryEndingBeforeValues(fieldValues.asList()))

0 commit comments

Comments
 (0)