I am trying to access a var which is pulled from a website when I use an API call it is being contained within a results var, I need to know how to access that and pull a specific piece of information from it to display in my app.
this is the data which is pulled:
{
days = 0;
hours = 0;
minutes = 0;
seconds = 10;
}
Result contains the value of minutes along with the above data I need to know how to access only the value of minutes to display it in my app, the user must be logged in to access this data which by this point they will be, below is the API call I used to access this data:
DispatchQueue.main.asyncAfter(deadline: .now() + 2) {
model.webView.evaluateJavaScript("AsgFW.sessionTimeView();") {
result, error in
if let result = result {
if result as! NSObject != NSNull(){
print("\(result)")
isLogin = false
print(isLogin)
counter = 0
}
}
}
}