How can i access a returned value from then() in JavaScript?
I have the following function:
function getResult(){
var promise = _myService.getAge();
var getResultPromise = promise.then(function(age){
return age;
})
return getResultPromise; //How do i get the age (value) here? *see image*
}
Or how would i access the value in the $$state object below?