Skip to content

[pro version] Problem with date format expires_at #321

@papipsycho

Description

@papipsycho

Hello,

i just installed the pro version and disable the free version, but when i want to refresh the token i got the error message :

{ "code": "jwt_auth_expired_refresh_token", "message": "Expired refresh token.", "data": { "status": 403 }}

so i start to check a bit what is the issue :

into the file : src/Actions/Auth/TokenRefreshRequestHandler.php
at line 103 you have :
if (strtotime($token->expires_at) < time()) {

so i checked the value of $token->expires_at and i got : 14 May 2025 7 h 48 min

and if you do strtotime('14 May 2025 7 h 48 min') you got false

i check what is your date format into your wordrpess

is j F Y G \h i \m\i\n

so the issue came from there you should use a simple date format instead of using the one from wordpress

i post on ticket on freshdesk week ago and i didn't have any answer so i try here

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions