Skip to content

Commit

Permalink
🚿
Browse files Browse the repository at this point in the history
  • Loading branch information
codemasher committed Apr 17, 2024
1 parent c5db278 commit 8b67cd7
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 3 deletions.
2 changes: 1 addition & 1 deletion examples/get-token/_flow-oauth1.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
header('Location: '.$provider->getAuthorizationURL($PARAMS));
}
// step 3: receive the access token
elseif(isset($_GET['oauth_token']) && isset($_GET['oauth_verifier'])){
elseif(isset($_GET['oauth_token'], $_GET['oauth_verifier'])){
$token = $provider->getAccessToken($_GET['oauth_token'], $_GET['oauth_verifier']);

// save the token [...]
Expand Down
2 changes: 0 additions & 2 deletions tests/Providers/Unit/LastFMTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -98,15 +98,13 @@ public function testParseTokenResponseNoTokenException():void{
* access token
*/


public function testGetAccessToken():void{
$this->setMockResponse($this->streamFactory->createStream($this::TEST_TOKEN));

$token = $this->provider->getAccessToken('code');

$this->assertSame('sk', $token->accessToken);
$this::assertSame('lfm-user', $token->extraParams['session']['name']);

}

public function testGetAccessTokenRequestBodyParams():void{
Expand Down

0 comments on commit 8b67cd7

Please sign in to comment.