Comments (3)
Hi @shadowsyntax ,
Sorry for the late response.
I'm not familiar with either Ionic or Firebase, but I suggest that you can try wrapping .logout()
with .getLoginStatus()
, which might solve the called without an access token
error.
ezfb.getLoginStatus(function (response) {
if (response && response.status === 'connected') {
ezfb.logout();
}
});
The thing is that Facebook JS SDK actually tries to maintain an active access token in it, which seems can only obtained through calling .getLoginStatus()
.
See also: FB.logout() called without an access token. javascript sdk
from angular-easyfb.
Hello @pc035860, I tried your trick and it works fine now. My apologies for getting back to you so late, been tackling some other programming issues.
Thanks a lot.
from angular-easyfb.
To use the access token with the FB.logout method, you need to ensure that you have obtained the access token during the login process and that it is available when you want to log out the user.
FB.logout(function(response) {
if ( 'connected' === response.status ) {
window.location.href = data.render.logout_url;
} else {
console.log( 'There has been an error.' );
}
}, {
access_token: data.render.accessToken
});
from angular-easyfb.
Related Issues (20)
- Facebook Comment And Like Track HOT 9
- Page Plugin not loading on iPad Safari iOS 9.2.1 HOT 1
- "Main" field in package.json is wrong HOT 2
- Upload photos from camera source HOT 3
- Won't initialize when `xfbml: false` given
- Unsupported Browser:: Facebook login does not work from chrome on iPhone. HOT 2
- Minified version of 1.4.4 causes injector error HOT 2
- Dynamic set the locale HOT 2
- Get ezfb to work with import HOT 2
- To show all public posts that are present in Page or a person in facebook?? HOT 3
- apk file created by android studio using ionic framework not working HOT 2
- facebook endpoint changed from *.net to *.com HOT 2
- Angular2 Version? HOT 2
- can i make the custom fb like button and call some controller function on click of that button. HOT 1
- doesn't render FB login button after navigating to different page and back HOT 3
- long-lived token
- How to use fb-login-button directive HOT 1
- In Android device error getting the sdk
- Login Button doesn't work HOT 3
- No way to exchange short-term tokens for long-term tokens
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from angular-easyfb.