Merge pull request #2976 from J-Cod3r/develop

[ISSUE #2956] simplify code
This commit is contained in:
杨翊 SionYang 2020-06-08 09:52:27 +08:00 committed by GitHub
commit ab22fc7f3b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 2 deletions

View File

@ -57,7 +57,7 @@ public class JwtTokenManager {
public String createToken(String userName) {
long now = (new Date()).getTime();
long now = System.currentTimeMillis();
Date validity;
validity = new Date(now + authConfigs.getTokenValidityInSeconds() * 1000L);

View File

@ -104,7 +104,7 @@ public class JwtTokenUtils {
/**
* Current time
*/
long now = (new Date()).getTime();
long now = System.currentTimeMillis();
/**
* Validity date
*/