Skip to content

Commit

Permalink
Fix the filter code snippet
Browse files Browse the repository at this point in the history
  • Loading branch information
henrikwirth authored Aug 27, 2020
1 parent d0faaab commit 6f4c18a
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,11 @@ The plugin offers some filters to hook into.
**Note: For security, we highly recommend, that the Auth Token is short lived. So do not set this higher than 300 seconds unless you know what you are doing.**

```php
add_filter('graphql_jwt_auth_expire', 60);
function custom_jwt_expiration( $expiration ) {
return 60;
}

add_filter('graphql_jwt_auth_expire', 'custom_jwt_expiration', 10);
```

- Argument: Expiration in seconds
Expand Down

0 comments on commit 6f4c18a

Please sign in to comment.