Skip to content

Commit 268c6e2

Browse files
committedOct 22, 2020
remove apply in android updateProfile
1 parent 3833e46 commit 268c6e2

File tree

1 file changed

+4
-4
lines changed
  • firebase-auth/src/androidMain/kotlin/dev/gitlive/firebase/auth

1 file changed

+4
-4
lines changed
 

‎firebase-auth/src/androidMain/kotlin/dev/gitlive/firebase/auth/user.kt

+4-4
Original file line numberDiff line numberDiff line change
@@ -46,10 +46,10 @@ actual class FirebaseUser internal constructor(val android: com.google.firebase.
4646
actual suspend fun updatePassword(password: String) = android.updatePassword(password).await().run { Unit }
4747
actual suspend fun updatePhoneNumber(credential: PhoneAuthCredential) = android.updatePhoneNumber(credential.android).await().run { Unit }
4848
actual suspend fun updateProfile(displayName: String?, photoUrl: String?) {
49-
val request = UserProfileChangeRequest.Builder().apply {
50-
this.displayName = displayName
51-
photoUri = photoURL?.let { Uri.parse(it) }
52-
}.build()
49+
val request = UserProfileChangeRequest.Builder()
50+
.setDisplayName(displayName)
51+
.setPhotoUri(photoURL?.let { Uri.parse(it) })
52+
.build()
5353
android.updateProfile(request).await()
5454
}
5555
actual suspend fun verifyBeforeUpdateEmail(newEmail: String, actionCodeSettings: ActionCodeSettings?) =

0 commit comments

Comments
 (0)
Failed to load comments.