diff --git a/index.html b/index.html index e2c6ea4..e8e54ae 100644 --- a/index.html +++ b/index.html @@ -26,7 +26,7 @@ FB.init({appId: '194478650562619', cookie: true}); FB.getLoginStatus(function(response) { - if (response.session) { + if (response.status === "connected") { init(); } else { // no user session available, someone you dont know @@ -36,7 +36,7 @@ function login() { FB.login(function(response) { - if (response.session) { + if (response.status === "connected") { init(); } else { alert('Login Failed!'); diff --git a/list.html b/list.html index 2135e8f..6b0173e 100644 --- a/list.html +++ b/list.html @@ -26,7 +26,7 @@ FB.init({appId: '194478650562619', cookie: true}); FB.getLoginStatus(function(response) { - if (response.session) { + if (response.status === "connected") { init(); } else { // no user session available, someone you dont know @@ -36,7 +36,7 @@ function login() { FB.login(function(response) { - if (response.session) { + if (response.status === "connected") { init(); } else { alert('Login Failed!');