"exp" field was wrongly returned as string instead of Long

This commit is contained in:
Mauro Mugnaini 2020-06-29 16:43:16 +02:00
parent 65e2882c2f
commit a8f328cf56
1 changed files with 3 additions and 3 deletions

View File

@ -75,12 +75,12 @@ public class JWTToken implements Serializable {
return payload;
}
public String getExp() {
return (String) getPayload().get("exp");
public Long getExp() {
return (Long) getPayload().get("exp");
}
public Date getExpAsDate() {
return new Date(Long.getLong(getExp()) * 1000);
return new Date(getExp() * 1000);
}
public Calendar getExpAsCalendar() {