title: Can't fetch data from Facebook SDK
body: <p>I made a <a href="http://en.wikipedia.org/wiki/CakePHP" rel="nofollow">CakePHP</a> plugin for social network authentification using Facebook, Twitter, Google, and LinkedIn. The whole plugin works 100% with no bug or error, but lately I tried to login via Facebook and I found myself unable to fetch data from the <a href="http://en.wikipedia.org/wiki/Application_programming_interface" rel="nofollow">API</a>.</p>
  
  <p>Here is what I've done.</p>
  
  <p><em>AuthController Facebook action</em></p>
  
  <pre><code>public function facebook(){
      $facebookObj = SocialAuth::init('facebook');
      $facebookLoginUrl = $facebookObj-&gt;getLoginUrl(array('scope' =&gt; SocialAuth::getConfig('facebook','permissions'),
          'canvas' =&gt; 1,
          'fbconnect' =&gt; 0,
          'redirect_uri' =&gt; SocialAuth::getConfig('facebook','redirect_uri')));
      $this-&gt;redirect($facebookLoginUrl);
  }
  </code></pre>
  
  <p><em>AuthController callback action</em></p>
  
  <pre><code>public function callback(){
      $facebookObj = SocialAuth::init('facebook');
      $facebookInfo = $facebookObj-&gt;getUser();
  
      if ($facebookInfo) { // $facebookInfo always return 0 (it was working before &gt;_&lt;)
          // ..
      }
  }
  </code></pre>
  
  <p><strong><em>$facebookInfo</strong> debug informations</em></p>
  
  <pre><code>/app/Plugin/SocialAuth/Controller/AuthsController.php (line 104)
  object(Facebook) {
      [protected] sharedSessionID =&gt; null
      [protected] kSupportedKeys =&gt; array(
          (int) 0 =&gt; 'state',
          (int) 1 =&gt; 'code',
          (int) 2 =&gt; 'access_token',
          (int) 3 =&gt; 'user_id'
      )
      [protected] DROP_QUERY_PARAMS =&gt; array(
          (int) 0 =&gt; 'code',
          (int) 1 =&gt; 'state',
          (int) 2 =&gt; 'signed_request'
      )
      [protected] appId =&gt; '503845519711145'
      [protected] appSecret =&gt; '--secret--'
      [protected] user =&gt; (int) 0
      [protected] signedRequest =&gt; null
      [protected] state =&gt; '59e2aba0d18dcc166d8c4aef0f1668c9'
      [protected] accessToken =&gt; '{app-id}|{app-secret}'
      [protected] fileUploadSupport =&gt; false
      [protected] trustForwarded =&gt; false
      [protected] allowSignedRequest =&gt; false
  }
  </code></pre>
  
  <p>How can I fix this problem?</p>