I'm currently working with the following piece of code:
var FACEBOOK = 'facebook';
$scope.handle_credentials = function (network) {
hello(network).api('me').then(function (json) {
dbService.handle_credentials(json)
});
};
$scope.loginFB = function () {
hello(FACEBOOK).login(handle_credentials(FACEBOOK))
};
However, I keep encountering this error:
handle_credentials is not defined
Does anyone know how to successfully pass parameters between AngularJS functions?