getExpiryDate static method
Implementation
static DateTime? getExpiryDate(String token) {
final Map<String, dynamic> payload = parseJwt(token);
if (payload['exp'] != null) {
return DateTime.fromMillisecondsSinceEpoch(0, isUtc: true)
.add(Duration(seconds: payload['exp']));
}
return null;
}