Skip to content

Commit

Permalink
fix: pass empty fields for customer object for android
Browse files Browse the repository at this point in the history
  • Loading branch information
cb-haripriyan committed Apr 27, 2023
1 parent 00b6e91 commit 87fce9b
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -86,9 +86,9 @@ internal fun convertQueryParamsToArray(queryParams: ReadableMap): Array<String>

internal fun convertReadableMapToCustomer(customerMap: ReadableMap): CBCustomer {
val id = customerMap.getString("id")
val firstName = customerMap.getString("firstName")
val lastName = customerMap.getString("lastName")
val email = customerMap.getString("email")
val firstName = customerMap.getString("firstName") ?: ""
val lastName = customerMap.getString("lastName") ?: ""
val email = customerMap.getString("email") ?: ""
return CBCustomer(id, firstName, lastName, email)
}

Expand Down

0 comments on commit 87fce9b

Please sign in to comment.