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

Userclass not found #24

Open
GRX opened this issue Oct 27, 2017 · 0 comments
Open

Userclass not found #24

GRX opened this issue Oct 27, 2017 · 0 comments

Comments

@GRX
Copy link

GRX commented Oct 27, 2017

Hi There,

I keep getting the following error when I try to access the user object.
PHP Fatal error: Uncaught Error: Class 'Discord\\OAuth\\Parts\\User' not found in ...

I copied the code directly from the example;

$refresh = $provider->getAccessToken('refresh_token', [
	'refresh_token' => $token->getRefreshToken(),
]);
echo pre_dump('Refresh Token',$refresh);

// Get the user object.
$user = $provider->getResourceOwner($token);
echo pre_dump($user);

$connections = $user->connections;
echo pre_dump('Connections',$connections);

// Get the guilds and connections.
$guilds = $user->guilds;
echo pre_dump('Guilds (and connections?)',$guilds);

But it stops at $user = $provider->getResourceOwner($token);

Am I missing resources or something?
Thank you in advance!

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