src/Vinelab/Auth/Social/Providers/Facebook/AccessToken.php
public function parseResponse(Response $response)
    {
        $json = $response->json();

        /*
         * The returned response must not be in JSON
         * format, unless it is an error.
         */
        if (!is_null($json)) {
            if (isset($json->error)) {
                $error = $json->error;
                throw new AccessTokenException($error->type.': '.$error->message, $error->code);
            }
        }

        $token = $response->content();

        return $this->parseToken($token);
    }
public function parseResponse(Response $response)
    {
        $json = $response->json();

        /*
         * The returned response must not be in JSON
         * format, unless it is an error.
         */
        if (!is_null($json)) {
            if (isset($json->error)) {
                $error = $json->error;
                throw new AccessTokenException($error->type.': '.$error->message, $error->code);
            }
        }

        $token = $response->content();

        return $this->parseToken($token);
    }
Parses an access token response.

@param Vinelab\Http\Response $response

@return array