Skip to content

Commit

Permalink
Fix exception type in Firebase bootcamp
Browse files Browse the repository at this point in the history
  • Loading branch information
AlSchlo authored May 31, 2023
1 parent 26cedf8 commit 513b656
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion project/bootcamp/firebase/ReadMe.md
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ db.child(PHONE_NB).setValue(EMAIL)
val future = CompletableFuture<String>()

db.child(phone.text.toString()).get().addOnSuccessListener {
if (it.value == null) future.completeExceptionally(NoSuchFieldException())
if (it.value == null) future.completeExceptionally(NoSuchElementException())
else future.complete(it.value as String)
}.addOnFailureListener {
future.completeExceptionally(it)
Expand Down

0 comments on commit 513b656

Please sign in to comment.