Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Twitch authentication error #24

Open
xlith opened this issue Feb 9, 2018 · 0 comments
Open

Twitch authentication error #24

xlith opened this issue Feb 9, 2018 · 0 comments

Comments

@xlith
Copy link

xlith commented Feb 9, 2018

We are trying to write an authantication module for our Drupal 8 website. We are using oAuth.io for external authantications (with social media platforms) every other platform works perfectly. But when we try to login with Twitch we get the error:

Notice: Trying to get property of non-object in OAuth_io\RequestObject->me() (line 133 of [root]/vendor/oauth-io/oauth/src/OAuth_io/RequestObject.php)

This is the code in our redirect page:

$oauth = new OAuth();
        $oauth->initialize(['oauthApiKey'], ['oauthSecretKey']);
        $request_object = $oauth->auth($provider, [
          'redirect' => true
        ]);
 $socialDataArray = $request_object->me('email'); [or ->me() -both the same]

This is very urgent. Could you please help?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant