You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
angular.js:12520 ReferenceError: facebookUser is not defined
on the line in the eventlistener where I call facebookUser.
$rootScope.$on('fbLoginSuccess', function(name, response) {
facebookUser.then(function(user) {
user.api('/me').then(function(response) {
console.log(response);
if (response.status === 'connected') {
// Logged into your app and Facebook.
$scope.facebooklogin(response.id);
} else if (response.status === 'not_authorized') {
// The person is logged into Facebook, but not your app.
$("#loginWarning").innerHTML = 'Please log ' +
'into this app.';
} else {
// The person is not logged into Facebook, so we're not sure if
// they are logged into this app or not.
$("#loginWarning").innerHTML = 'Please log ' +
'into Facebook.';
}
});
});
});
I link facebookUtils.js after angular and before my app.
This is how I inject the dependancy:
Hi,
I keep getting the above mentioned error
on the line in the eventlistener where I call facebookUser.
I link facebookUtils.js after angular and before my app.
This is how I inject the dependancy:
What am I doing wrong? Am I doing anything wrong?
The text was updated successfully, but these errors were encountered: