|
if(DateTime.fromMillisecondsSinceEpoch(payload["exp"]*1000).isAfter(DateTime.now())) { |
The if statement should be:
if(DateTime.now().isAfter(DateTime.fromMillisecondsSinceEpoch(payload["exp"] * 1000))){
}
Your statement always return true as the value is negative.
Thank You.
jwt-tutorial-flutter/lib/main.dart
Line 39 in dcda3bd
The if statement should be:
Your statement always return true as the value is negative.
Thank You.