Is this the right way to use a function that returns a promise which resolves with either true or false inside an if condition?
if(functionName().then(function(data){return data})){
//execute code
}
Is this the right way to use a function that returns a promise which resolves with either true or false inside an if condition?
if(functionName().then(function(data){return data})){
//execute code
}