diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index a5bfdc1a9..e0ae15d91 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -14,10 +14,11 @@ jobs: steps: - uses: actions/checkout@v2 - - name: Set up JDK 1.8 - uses: actions/setup-java@v1 + - name: Set up JDK + uses: actions/setup-java@v2 with: - java-version: 1.8 + distribution: 'zulu' + java-version: '11' - name: Setup versions uses: eskatos/gradle-command-action@v1 with: diff --git a/.github/workflows/pull_request.yml b/.github/workflows/pull_request.yml index 99cda9530..107872fe7 100644 --- a/.github/workflows/pull_request.yml +++ b/.github/workflows/pull_request.yml @@ -13,48 +13,49 @@ jobs: runs-on: macos-latest steps: - - uses: actions/checkout@v2 - - name: Set up JDK 1.8 - uses: actions/setup-java@v1 - with: - java-version: 1.8 - - name: Grant execute permission for gradlew - run: chmod +x gradlew - - name: Install Carthage - run: brew list carthage || brew install carthage - - name: Install Firebase tools - run: npm install -g firebase-tools - - name: Start Firebase emulator - run: "firebase emulators:start --config=./test/firebase.json &" - - name: Assemble - run: ./gradlew assemble - - name: Run JS Tests - run: ./gradlew cleanTest jsTest - - name: Upload JS test artifact - uses: actions/upload-artifact@v2 - if: failure() - with: - name: "JS Test Report HTML" - path: "firebase-firestore/build/reports/tests/jsTest/" - - name: Run iOS Tests - run: ./gradlew cleanTest iosX64Test - - name: Upload iOS test artifact - uses: actions/upload-artifact@v2 - if: failure() - with: - name: "iOS Test Report HTML" - path: "firebase-firestore/build/reports/tests/iosTest/" - - name: Run Android Instrumented Tests - uses: reactivecircus/android-emulator-runner@v2 - with: - api-level: 29 - target: google_apis - arch: x86_64 - profile: Nexus 6 - script: ./gradlew connectedAndroidTest - - name: Upload Android test artifact - uses: actions/upload-artifact@v2 - if: failure() - with: - name: "Android Test Report HTML" - path: "firebase-firestore/build/reports/tests/androidTests/" + - uses: actions/checkout@v2 + - name: Set up JDK + uses: actions/setup-java@v2 + with: + distribution: 'zulu' + java-version: '11' + - name: Grant execute permission for gradlew + run: chmod +x gradlew + - name: Install Carthage + run: brew list carthage || brew install carthage + - name: Install Firebase tools + run: npm install -g firebase-tools + - name: Start Firebase emulator + run: "firebase emulators:start --config=./test/firebase.json &" + - name: Assemble + run: ./gradlew assemble + - name: Run JS Tests + run: ./gradlew cleanTest jsTest + - name: Upload JS test artifact + uses: actions/upload-artifact@v2 + if: failure() + with: + name: "JS Test Report HTML" + path: "firebase-firestore/build/reports/tests/jsTest/" + - name: Run iOS Tests + run: ./gradlew cleanTest iosX64Test + - name: Upload iOS test artifact + uses: actions/upload-artifact@v2 + if: failure() + with: + name: "iOS Test Report HTML" + path: "firebase-firestore/build/reports/tests/iosTest/" + - name: Run Android Instrumented Tests + uses: reactivecircus/android-emulator-runner@v2 + with: + api-level: 29 + target: google_apis + arch: x86_64 + profile: Nexus 6 + script: ./gradlew connectedAndroidTest + - name: Upload Android test artifact + uses: actions/upload-artifact@v2 + if: failure() + with: + name: "Android Test Report HTML" + path: "firebase-firestore/build/reports/tests/androidTests/" diff --git a/build.gradle.kts b/build.gradle.kts index aaf02a055..bf5a782b3 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -4,7 +4,7 @@ import org.gradle.api.tasks.testing.logging.TestExceptionFormat import org.gradle.api.tasks.testing.logging.TestLogEvent plugins { - kotlin("multiplatform") version "1.5.10" apply false + kotlin("multiplatform") version "1.5.21" apply false id("base") } @@ -18,7 +18,7 @@ buildscript { } } dependencies { - classpath("com.android.tools.build:gradle:4.2.1") + classpath("com.android.tools.build:gradle:7.0.0") classpath("com.adarshr:gradle-test-logger-plugin:2.1.1") } } @@ -207,19 +207,18 @@ subprojects { } dependencies { - "commonMainImplementation"(kotlin("stdlib-common")) - "commonMainImplementation"("org.jetbrains.kotlinx:kotlinx-coroutines-core:1.5.0") - "jsMainImplementation"(kotlin("stdlib-js")) - "androidMainImplementation"("org.jetbrains.kotlinx:kotlinx-coroutines-play-services:1.5.0") + "commonMainImplementation"("org.jetbrains.kotlinx:kotlinx-coroutines-core:1.5.1") + "androidMainImplementation"("org.jetbrains.kotlinx:kotlinx-coroutines-play-services:1.5.1") + "androidMainImplementation"(platform("com.google.firebase:firebase-bom:28.3.1")) "commonTestImplementation"(kotlin("test-common")) "commonTestImplementation"(kotlin("test-annotations-common")) - "commonTestImplementation"("org.jetbrains.kotlinx:kotlinx-coroutines-core:1.5.0") + "commonTestImplementation"("org.jetbrains.kotlinx:kotlinx-coroutines-core:1.5.1") "jsTestImplementation"(kotlin("test-js")) "androidAndroidTestImplementation"(kotlin("test-junit")) "androidAndroidTestImplementation"("junit:junit:4.13.2") - "androidAndroidTestImplementation"("androidx.test:core:1.3.0") - "androidAndroidTestImplementation"("androidx.test.ext:junit:1.1.2") - "androidAndroidTestImplementation"("androidx.test:runner:1.3.0") + "androidAndroidTestImplementation"("androidx.test:core:1.4.0") + "androidAndroidTestImplementation"("androidx.test.ext:junit:1.1.3") + "androidAndroidTestImplementation"("androidx.test:runner:1.4.0") } } diff --git a/firebase-app/build.gradle.kts b/firebase-app/build.gradle.kts index 9bf98a6a7..b9bbd9f7c 100644 --- a/firebase-app/build.gradle.kts +++ b/firebase-app/build.gradle.kts @@ -18,10 +18,10 @@ repositories { } android { - compileSdkVersion(property("targetSdkVersion") as Int) + compileSdk = property("targetSdkVersion") as Int defaultConfig { - minSdkVersion(property("minSdkVersion") as Int) - targetSdkVersion(property("targetSdkVersion") as Int) + minSdk = property("minSdkVersion") as Int + targetSdk = property("targetSdkVersion") as Int testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner" } sourceSets { @@ -35,11 +35,11 @@ android { } } packagingOptions { - pickFirst("META-INF/kotlinx-serialization-core.kotlin_module") - pickFirst("META-INF/AL2.0") - pickFirst("META-INF/LGPL2.1") + resources.pickFirsts.add("META-INF/kotlinx-serialization-core.kotlin_module") + resources.pickFirsts.add("META-INF/AL2.0") + resources.pickFirsts.add("META-INF/LGPL2.1") } - lintOptions { + lint { isAbortOnError = false } } @@ -127,7 +127,7 @@ kotlin { val androidMain by getting { dependencies { - api("com.google.firebase:firebase-common:20.0.0") + api("com.google.firebase:firebase-common-ktx") } } diff --git a/firebase-app/package.json b/firebase-app/package.json index 95feb0407..cd1916bca 100644 --- a/firebase-app/package.json +++ b/firebase-app/package.json @@ -24,8 +24,8 @@ "homepage": "https://github.com/GitLiveApp/firebase-kotlin-sdk", "dependencies": { "@gitlive/firebase-common": "1.4.1", - "firebase": "8.6.7", - "kotlin": "1.5.10", - "kotlinx-coroutines-core": "1.5.0" + "firebase": "8.8.1", + "kotlin": "1.5.21", + "kotlinx-coroutines-core": "1.5.1" } } diff --git a/firebase-app/src/nativeInterop/cinterop/Cartfile b/firebase-app/src/nativeInterop/cinterop/Cartfile index 6ebb8fc11..e0f994544 100644 --- a/firebase-app/src/nativeInterop/cinterop/Cartfile +++ b/firebase-app/src/nativeInterop/cinterop/Cartfile @@ -1 +1 @@ -binary "https://dl.google.com/dl/firebase/ios/carthage/FirebaseAnalyticsBinary.json" == 8.2.0 +binary "https://dl.google.com/dl/firebase/ios/carthage/FirebaseAnalyticsBinary.json" == 8.5.0 diff --git a/firebase-auth/build.gradle.kts b/firebase-auth/build.gradle.kts index bdc6f93e0..51bff83d9 100644 --- a/firebase-auth/build.gradle.kts +++ b/firebase-auth/build.gradle.kts @@ -24,10 +24,10 @@ plugins { //} android { - compileSdkVersion(property("targetSdkVersion") as Int) + compileSdk = property("targetSdkVersion") as Int defaultConfig { - minSdkVersion(property("minSdkVersion") as Int) - targetSdkVersion(property("targetSdkVersion") as Int) + minSdk = property("minSdkVersion") as Int + targetSdk = property("targetSdkVersion") as Int testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner" } sourceSets { @@ -45,11 +45,11 @@ android { } } packagingOptions { - pickFirst("META-INF/kotlinx-serialization-core.kotlin_module") - pickFirst("META-INF/AL2.0") - pickFirst("META-INF/LGPL2.1") + resources.pickFirsts.add("META-INF/kotlinx-serialization-core.kotlin_module") + resources.pickFirsts.add("META-INF/AL2.0") + resources.pickFirsts.add("META-INF/LGPL2.1") } - lintOptions { + lint { isAbortOnError = false } } @@ -161,7 +161,7 @@ kotlin { val androidMain by getting { dependencies { - api("com.google.firebase:firebase-auth:21.0.1") + api("com.google.firebase:firebase-auth-ktx") } } diff --git a/firebase-auth/package.json b/firebase-auth/package.json index c4db648ac..393cdbfbb 100644 --- a/firebase-auth/package.json +++ b/firebase-auth/package.json @@ -24,8 +24,8 @@ "homepage": "https://github.com/GitLiveApp/firebase-kotlin-sdk", "dependencies": { "@gitlive/firebase-app": "1.4.1", - "firebase": "8.6.7", - "kotlin": "1.5.10", - "kotlinx-coroutines-core": "1.5.0" + "firebase": "8.8.1", + "kotlin": "1.5.21", + "kotlinx-coroutines-core": "1.5.1" } } diff --git a/firebase-auth/src/jsMain/kotlin/dev/gitlive/firebase/auth/auth.kt b/firebase-auth/src/jsMain/kotlin/dev/gitlive/firebase/auth/auth.kt index 8f270e351..50f97e2c4 100644 --- a/firebase-auth/src/jsMain/kotlin/dev/gitlive/firebase/auth/auth.kt +++ b/firebase-auth/src/jsMain/kotlin/dev/gitlive/firebase/auth/auth.kt @@ -148,7 +148,7 @@ private inline fun rethrow(function: () -> R): R { } } -private fun errorToException(cause: dynamic) = when(val code = cause.code?.toString()?.toLowerCase()) { +private fun errorToException(cause: dynamic) = when(val code = cause.code?.toString()?.lowercase()) { "auth/invalid-user-token" -> FirebaseAuthInvalidUserException(code, cause) "auth/requires-recent-login" -> FirebaseAuthRecentLoginRequiredException(code, cause) "auth/user-disabled" -> FirebaseAuthInvalidUserException(code, cause) diff --git a/firebase-auth/src/nativeInterop/cinterop/Cartfile b/firebase-auth/src/nativeInterop/cinterop/Cartfile index fd7c50e01..c87f8aa12 100644 --- a/firebase-auth/src/nativeInterop/cinterop/Cartfile +++ b/firebase-auth/src/nativeInterop/cinterop/Cartfile @@ -1 +1 @@ -binary "https://dl.google.com/dl/firebase/ios/carthage/FirebaseAuthBinary.json" == 8.2.0 +binary "https://dl.google.com/dl/firebase/ios/carthage/FirebaseAuthBinary.json" == 8.5.0 diff --git a/firebase-common/build.gradle.kts b/firebase-common/build.gradle.kts index 0d7357e6d..3a2f2282d 100644 --- a/firebase-common/build.gradle.kts +++ b/firebase-common/build.gradle.kts @@ -9,14 +9,14 @@ version = project.property("firebase-common.version") as String plugins { id("com.android.library") kotlin("multiplatform") - kotlin("plugin.serialization") version "1.5.10" + kotlin("plugin.serialization") version "1.5.21" } android { - compileSdkVersion(property("targetSdkVersion") as Int) + compileSdk = property("targetSdkVersion") as Int defaultConfig { - minSdkVersion(property("minSdkVersion") as Int) - targetSdkVersion(property("targetSdkVersion") as Int) + minSdk = property("minSdkVersion") as Int + targetSdk = property("targetSdkVersion") as Int testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner" } sourceSets { @@ -31,11 +31,11 @@ android { } } packagingOptions { - pickFirst("META-INF/kotlinx-serialization-core.kotlin_module") - pickFirst("META-INF/AL2.0") - pickFirst("META-INF/LGPL2.1") + resources.pickFirsts.add("META-INF/kotlinx-serialization-core.kotlin_module") + resources.pickFirsts.add("META-INF/AL2.0") + resources.pickFirsts.add("META-INF/LGPL2.1") } - lintOptions { + lint { isAbortOnError = false } } @@ -89,13 +89,13 @@ kotlin { val commonMain by getting { dependencies { - api("org.jetbrains.kotlinx:kotlinx-serialization-core:1.2.0") + api("org.jetbrains.kotlinx:kotlinx-serialization-core:1.2.2") } } val androidMain by getting { dependencies { - api("com.google.firebase:firebase-common:20.0.0") + api("com.google.firebase:firebase-common-ktx") } } @@ -103,7 +103,7 @@ kotlin { val jsMain by getting { dependencies { - api(npm("firebase", "8.2.0")) + api(npm("firebase", "8.7.1")) } } } diff --git a/firebase-common/package.json b/firebase-common/package.json index 27d604740..885ace498 100644 --- a/firebase-common/package.json +++ b/firebase-common/package.json @@ -23,9 +23,9 @@ }, "homepage": "https://github.com/GitLiveApp/firebase-kotlin-multiplatform-sdk", "dependencies": { - "firebase": "8.6.7", - "kotlin": "1.5.10", - "kotlinx-coroutines-core": "1.5.0", - "kotlinx-serialization-kotlinx-serialization-runtime": "1.2.0" + "firebase": "8.8.1", + "kotlin": "1.5.21", + "kotlinx-coroutines-core": "1.5.1", + "kotlinx-serialization-kotlinx-serialization-runtime": "1.2.2" } } diff --git a/firebase-config/build.gradle.kts b/firebase-config/build.gradle.kts index 9ce949fb7..117069ab5 100644 --- a/firebase-config/build.gradle.kts +++ b/firebase-config/build.gradle.kts @@ -13,10 +13,10 @@ plugins { } android { - compileSdkVersion(property("targetSdkVersion") as Int) + compileSdk = property("targetSdkVersion") as Int defaultConfig { - minSdkVersion(property("minSdkVersion") as Int) - targetSdkVersion(property("targetSdkVersion") as Int) + minSdk = property("minSdkVersion") as Int + targetSdk = property("targetSdkVersion") as Int testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner" } sourceSets { @@ -33,11 +33,11 @@ android { } } packagingOptions { - pickFirst("META-INF/kotlinx-serialization-core.kotlin_module") - pickFirst("META-INF/AL2.0") - pickFirst("META-INF/LGPL2.1") + resources.pickFirsts.add("META-INF/kotlinx-serialization-core.kotlin_module") + resources.pickFirsts.add("META-INF/AL2.0") + resources.pickFirsts.add("META-INF/LGPL2.1") } - lintOptions { + lint { isAbortOnError = false } } @@ -122,8 +122,8 @@ kotlin { sourceSets { all { languageSettings.apply { - apiVersion = "1.4" - languageVersion = "1.4" + apiVersion = "1.5" + languageVersion = "1.5" progressiveMode = true useExperimentalAnnotation("kotlinx.coroutines.ExperimentalCoroutinesApi") } @@ -138,7 +138,7 @@ kotlin { val androidMain by getting { dependencies { - api("com.google.firebase:firebase-config-ktx:21.0.0") + api("com.google.firebase:firebase-config-ktx") } } diff --git a/firebase-config/package.json b/firebase-config/package.json index aed5b331a..ed179cfcb 100644 --- a/firebase-config/package.json +++ b/firebase-config/package.json @@ -24,8 +24,8 @@ "homepage": "https://github.com/GitLiveApp/firebase-kotlin-sdk", "dependencies": { "@gitlive/firebase-app": "1.4.1", - "firebase": "8.5.0", - "kotlin": "1.4.31", - "kotlinx-coroutines-core": "1.4.3" + "firebase": "8.8.1", + "kotlin": "1.5.21", + "kotlinx-coroutines-core": "1.5.1" } } diff --git a/firebase-config/src/jsMain/kotlin/dev/gitlive/firebase/remoteconfig/FirebaseRemoteConfig.kt b/firebase-config/src/jsMain/kotlin/dev/gitlive/firebase/remoteconfig/FirebaseRemoteConfig.kt index 92e4eaa6e..b1b19825f 100644 --- a/firebase-config/src/jsMain/kotlin/dev/gitlive/firebase/remoteconfig/FirebaseRemoteConfig.kt +++ b/firebase-config/src/jsMain/kotlin/dev/gitlive/firebase/remoteconfig/FirebaseRemoteConfig.kt @@ -111,7 +111,7 @@ internal inline fun rethrow(function: () -> R): R { internal fun errorToException(error: dynamic) = (error?.code ?: error?.message ?: "") .toString() - .toLowerCase() + .lowercase() .let { code -> when { else -> { diff --git a/firebase-config/src/nativeInterop/cinterop/Cartfile b/firebase-config/src/nativeInterop/cinterop/Cartfile index ee1f07083..525ebedd6 100644 --- a/firebase-config/src/nativeInterop/cinterop/Cartfile +++ b/firebase-config/src/nativeInterop/cinterop/Cartfile @@ -1 +1 @@ -binary "https://dl.google.com/dl/firebase/ios/carthage/FirebaseRemoteConfigBinary.json" == 8.1.0 +binary "https://dl.google.com/dl/firebase/ios/carthage/FirebaseRemoteConfigBinary.json" == 8.5.0 diff --git a/firebase-database/build.gradle.kts b/firebase-database/build.gradle.kts index 7567d35ef..bc10120a3 100644 --- a/firebase-database/build.gradle.kts +++ b/firebase-database/build.gradle.kts @@ -18,10 +18,10 @@ repositories { } android { - compileSdkVersion(property("targetSdkVersion") as Int) + compileSdk = property("targetSdkVersion") as Int defaultConfig { - minSdkVersion(property("minSdkVersion") as Int) - targetSdkVersion(property("targetSdkVersion") as Int) + minSdk = property("minSdkVersion") as Int + targetSdk = property("targetSdkVersion") as Int } sourceSets { getByName("main") { @@ -34,11 +34,11 @@ android { } } packagingOptions { - pickFirst("META-INF/kotlinx-serialization-core.kotlin_module") - pickFirst("META-INF/AL2.0") - pickFirst("META-INF/LGPL2.1") + resources.pickFirsts.add("META-INF/kotlinx-serialization-core.kotlin_module") + resources.pickFirsts.add("META-INF/AL2.0") + resources.pickFirsts.add("META-INF/LGPL2.1") } - lintOptions { + lint { isAbortOnError = false } } @@ -139,7 +139,7 @@ kotlin { val androidMain by getting { dependencies { - api("com.google.firebase:firebase-database:20.0.0") + api("com.google.firebase:firebase-database-ktx") } } diff --git a/firebase-database/package.json b/firebase-database/package.json index 87d988d5a..c2eedf3cd 100644 --- a/firebase-database/package.json +++ b/firebase-database/package.json @@ -24,8 +24,8 @@ "homepage": "https://github.com/GitLiveApp/firebase-kotlin-sdk", "dependencies": { "@gitlive/firebase-app": "1.4.1", - "firebase": "8.6.7", - "kotlin": "1.5.10", - "kotlinx-coroutines-core": "1.5.0" + "firebase": "8.8.1", + "kotlin": "1.5.21", + "kotlinx-coroutines-core": "1.5.1" } } diff --git a/firebase-database/src/jsMain/kotlin/dev/gitlive/firebase/database/database.kt b/firebase-database/src/jsMain/kotlin/dev/gitlive/firebase/database/database.kt index a4f9898b6..9fbc04bba 100644 --- a/firebase-database/src/jsMain/kotlin/dev/gitlive/firebase/database/database.kt +++ b/firebase-database/src/jsMain/kotlin/dev/gitlive/firebase/database/database.kt @@ -62,7 +62,7 @@ actual open class Query internal constructor(open val js: firebase.database.Quer actual fun childEvents(vararg types: ChildEvent.Type) = callbackFlow { val listeners = rethrow { types.map { type -> - "child_${type.name.toLowerCase()}".let { eventType -> + "child_${type.name.lowercase()}".let { eventType -> eventType to js.on( eventType, { snapshot, previousChildName -> diff --git a/firebase-database/src/nativeInterop/cinterop/Cartfile b/firebase-database/src/nativeInterop/cinterop/Cartfile index 827161b83..3391e187f 100644 --- a/firebase-database/src/nativeInterop/cinterop/Cartfile +++ b/firebase-database/src/nativeInterop/cinterop/Cartfile @@ -1 +1 @@ -binary "https://dl.google.com/dl/firebase/ios/carthage/FirebaseDatabaseBinary.json" == 8.2.0 +binary "https://dl.google.com/dl/firebase/ios/carthage/FirebaseDatabaseBinary.json" == 8.5.0 diff --git a/firebase-firestore/build.gradle.kts b/firebase-firestore/build.gradle.kts index a3020d95c..bafa41f76 100644 --- a/firebase-firestore/build.gradle.kts +++ b/firebase-firestore/build.gradle.kts @@ -10,14 +10,14 @@ version = project.property("firebase-firestore.version") as String plugins { id("com.android.library") kotlin("multiplatform") - kotlin("plugin.serialization") version "1.5.10" + kotlin("plugin.serialization") version "1.5.21" } android { - compileSdkVersion(property("targetSdkVersion") as Int) + compileSdk = property("targetSdkVersion") as Int defaultConfig { - minSdkVersion(property("minSdkVersion") as Int) - targetSdkVersion(property("targetSdkVersion") as Int) + minSdk = property("minSdkVersion") as Int + targetSdk = property("targetSdkVersion") as Int testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner" multiDexEnabled = true } @@ -36,12 +36,12 @@ android { } } packagingOptions { - pickFirst("META-INF/kotlinx-serialization-core.kotlin_module") - pickFirst("META-INF/AL2.0") - pickFirst("META-INF/LGPL2.1") - pickFirst("androidsupportmultidexversion.txt") + resources.pickFirsts.add("META-INF/kotlinx-serialization-core.kotlin_module") + resources.pickFirsts.add("META-INF/AL2.0") + resources.pickFirsts.add("META-INF/LGPL2.1") + resources.pickFirsts.add("androidsupportmultidexversion.txt") } - lintOptions { + lint { isAbortOnError = false } } @@ -145,7 +145,7 @@ kotlin { val androidMain by getting { dependencies { - api("com.google.firebase:firebase-firestore:23.0.1") + api("com.google.firebase:firebase-firestore-ktx") } } diff --git a/firebase-firestore/package.json b/firebase-firestore/package.json index a682e1ffb..b06b89a2b 100644 --- a/firebase-firestore/package.json +++ b/firebase-firestore/package.json @@ -24,8 +24,8 @@ "homepage": "https://github.com/GitLiveApp/firebase-kotlin-sdk", "dependencies": { "@gitlive/firebase-app": "1.4.1", - "firebase": "8.6.7", - "kotlin": "1.5.10", - "kotlinx-coroutines-core": "1.5.0" + "firebase": "8.8.1", + "kotlin": "1.5.21", + "kotlinx-coroutines-core": "1.5.1" } } diff --git a/firebase-firestore/src/jsMain/kotlin/dev/gitlive/firebase/firestore/firestore.kt b/firebase-firestore/src/jsMain/kotlin/dev/gitlive/firebase/firestore/firestore.kt index e2f82294f..b72393afd 100644 --- a/firebase-firestore/src/jsMain/kotlin/dev/gitlive/firebase/firestore/firestore.kt +++ b/firebase-firestore/src/jsMain/kotlin/dev/gitlive/firebase/firestore/firestore.kt @@ -478,7 +478,7 @@ inline fun rethrow(function: () -> R): R { fun errorToException(e: dynamic) = (e?.code ?: e?.message ?: "") .toString() - .toLowerCase() + .lowercase() .let { when { "cancelled" in it -> FirebaseFirestoreException(e, FirestoreExceptionCode.CANCELLED) diff --git a/firebase-firestore/src/nativeInterop/cinterop/Cartfile b/firebase-firestore/src/nativeInterop/cinterop/Cartfile index f8ae9fc08..f8ef0e3ab 100644 --- a/firebase-firestore/src/nativeInterop/cinterop/Cartfile +++ b/firebase-firestore/src/nativeInterop/cinterop/Cartfile @@ -1 +1 @@ -binary "https://dl.google.com/dl/firebase/ios/carthage/FirebaseFirestoreBinary.json" == 8.2.0 +binary "https://dl.google.com/dl/firebase/ios/carthage/FirebaseFirestoreBinary.json" == 8.5.0 diff --git a/firebase-functions/build.gradle.kts b/firebase-functions/build.gradle.kts index 7287c2d93..5d4f7454a 100644 --- a/firebase-functions/build.gradle.kts +++ b/firebase-functions/build.gradle.kts @@ -13,10 +13,10 @@ plugins { } android { - compileSdkVersion(property("targetSdkVersion") as Int) + compileSdk = property("targetSdkVersion") as Int defaultConfig { - minSdkVersion(property("minSdkVersion") as Int) - targetSdkVersion(property("targetSdkVersion") as Int) + minSdk = property("minSdkVersion") as Int + targetSdk = property("targetSdkVersion") as Int } sourceSets { getByName("main") { @@ -29,11 +29,11 @@ android { } } packagingOptions { - pickFirst("META-INF/kotlinx-serialization-core.kotlin_module") - pickFirst("META-INF/AL2.0") - pickFirst("META-INF/LGPL2.1") + resources.pickFirsts.add("META-INF/kotlinx-serialization-core.kotlin_module") + resources.pickFirsts.add("META-INF/AL2.0") + resources.pickFirsts.add("META-INF/LGPL2.1") } - lintOptions { + lint { isAbortOnError = false } } @@ -133,7 +133,7 @@ kotlin { val androidMain by getting { dependencies { - api("com.google.firebase:firebase-functions:20.0.0") + api("com.google.firebase:firebase-functions-ktx") } } diff --git a/firebase-functions/package.json b/firebase-functions/package.json index 34169acdf..a2e96aec7 100644 --- a/firebase-functions/package.json +++ b/firebase-functions/package.json @@ -24,8 +24,8 @@ "homepage": "https://github.com/GitLiveApp/firebase-kotlin-sdk", "dependencies": { "@gitlive/firebase-app": "1.4.1", - "firebase": "8.6.7", - "kotlin": "1.5.0", - "kotlinx-coroutines-core": "1.5.0" + "firebase": "8.8.1", + "kotlin": "1.5.21", + "kotlinx-coroutines-core": "1.5.1" } } diff --git a/firebase-functions/src/nativeInterop/cinterop/Cartfile b/firebase-functions/src/nativeInterop/cinterop/Cartfile index 4a1605b0c..75898582b 100644 --- a/firebase-functions/src/nativeInterop/cinterop/Cartfile +++ b/firebase-functions/src/nativeInterop/cinterop/Cartfile @@ -1 +1 @@ -binary "https://dl.google.com/dl/firebase/ios/carthage/FirebaseFunctionsBinary.json" == 8.2.0 +binary "https://dl.google.com/dl/firebase/ios/carthage/FirebaseFunctionsBinary.json" == 8.5.0 diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties index a1e0e6cac..469b8ac11 100644 --- a/gradle/wrapper/gradle-wrapper.properties +++ b/gradle/wrapper/gradle-wrapper.properties @@ -3,4 +3,4 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-7.0-all.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-7.0.2-all.zip