Open anmolmalhotra opened 6 years ago
The payUResponse comes as Any in PUCBWebVCDelegate protocol and when I try to change Any to [String: Any] it doesn't do that.
payUResponse
Any
PUCBWebVCDelegate
[String: Any]
Here's the code:
func payUSuccessResponse(_ payUResponse: Any!, surlResponse: Any!) { if payUResponse != nil { print(payUResponse) } if let response = payUResponse as? [String: Any] { print(response) if let id = response["id"] as? Int { print("ID", id) createBooking(with: "\(id)", and: false) } } }
It is failing at if let response =. Can you tell me how I am going to fetch id from payUResponse?
if let response =
id
@anmolmalhotra Have you got the solution for this ? I'm also facing same issue...
The
payUResponse
comes asAny
inPUCBWebVCDelegate
protocol and when I try to changeAny
to[String: Any]
it doesn't do that.Here's the code:
It is failing at
if let response =
. Can you tell me how I am going to fetchid
from payUResponse?