The more important question is how to deal with the resultant callback hell.
As an aside, there is an alternative: passing a default value. This is Swift syntax:
let favoriteIceCream = [
"Paul": "Chocolate",
"Sophie": "Vanilla"
]
let result = favoriteIceCream["Charlotte", default: "Unknown"]