Skip to content

Commit

Permalink
chore: explicit third parameter to decode function in README
Browse files Browse the repository at this point in the history
  • Loading branch information
bshaffer committed Nov 4, 2021
1 parent bc0df64 commit cf81444
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion README.md
Expand Up @@ -43,7 +43,7 @@ $payload = array(
* https://tools.ietf.org/html/draft-ietf-jose-json-web-algorithms-40
* for a list of spec-compliant algorithms.
*/
$jwt = JWT::encode($payload, $key);
$jwt = JWT::encode($payload, $key, 'HS256');
$decoded = JWT::decode($jwt, new Key($key, 'HS256'));

print_r($decoded);
Expand Down

0 comments on commit cf81444

Please sign in to comment.