Skip to content

Commit

Permalink
(feat)Implemented a new feature in the function to check the expirati…
Browse files Browse the repository at this point in the history
…on time of JWTs
  • Loading branch information
P-1000 committed Oct 4, 2023
1 parent 598b8d8 commit b4a7bf1
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/lib/isJWTExpiration.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,7 @@ export default function isJWTExpiration(token) {
const currentTimestamp = Math.floor(Date.now() / 1000);

Check failure on line 10 in src/lib/isJWTExpiration.js

View workflow job for this annotation

GitHub Actions / Run tests on Node.js 14

Expected indentation of 6 spaces but found 8

Check failure on line 10 in src/lib/isJWTExpiration.js

View workflow job for this annotation

GitHub Actions / Run tests on Node.js 10

Expected indentation of 6 spaces but found 8

Check failure on line 10 in src/lib/isJWTExpiration.js

View workflow job for this annotation

GitHub Actions / Run tests on Node.js 8

Expected indentation of 6 spaces but found 8
return payload.exp >= currentTimestamp;
}

return false;
return false
} catch (error) {
return false;
}
Expand Down

0 comments on commit b4a7bf1

Please sign in to comment.