Skip to content
Snippets Groups Projects
Commit 5fc226b8 authored by Andjelko Horvat's avatar Andjelko Horvat
Browse files

authfacebook: minor uid check fix.

git-svn-id: https://simplesamlphp.googlecode.com/svn/trunk@3007 44740490-163a-0410-bde0-09ae8108e29a
parent fdc66742
No related branches found
No related tags found
No related merge requests found
......@@ -90,9 +90,9 @@ class sspmod_authfacebook_Auth_Source_Facebook extends SimpleSAML_Auth_Source {
$facebook = new sspmod_authfacebook_Facebook(array('appId' => $this->api_key, 'secret' => $this->secret), $state);
$uid = $facebook->getUser();
if (isset($uid)) {
if (isset($uid) && $uid) {
try {
$info = $facebook->api("/me");
$info = $facebook->api("/" . $uid);
} catch (FacebookApiException $e) {
throw new SimpleSAML_Error_AuthSource($this->authId, 'Error getting user profile.', $e);
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment