thephpleague / oauth2-client

Easy integration with OAuth 2.0 service providers.
http://oauth2-client.thephpleague.com
MIT License
3.64k stars 751 forks source link

get a specified value in the access token #888

Open hendeavors opened 3 years ago

hendeavors commented 3 years ago

Provide the ability to get a value from the access token by the offset.

Before:

$value = $token->getValues()['some_offset'] ?? null;

After:

$value = $token->getValue('some_offset');

codecov[bot] commented 3 years ago

Codecov Report

Merging #888 (96c80fc) into master (77def43) will not change coverage. The diff coverage is 100.00%.

Impacted file tree graph

@@             Coverage Diff             @@
##              master      #888   +/-   ##
===========================================
  Coverage     100.00%   100.00%           
- Complexity       180       185    +5     
===========================================
  Files             20        20           
  Lines            464       472    +8     
===========================================
+ Hits             464       472    +8     
Impacted Files Coverage Δ
src/Token/AccessToken.php 100.00% <100.00%> (ø)