difference static method
Implementation
static Duration difference(String firstRulesDate, String secondRulesDate) {
try {
final firstDate =
DateTime.parse(firstRulesDate.replaceAll("'", "").trim());
final secondDate =
DateTime.parse(secondRulesDate.replaceAll("'", "").trim());
return secondDate.difference(firstDate);
} catch (e) {
return Duration(days: 0, hours: 0, minutes: 0, seconds: 0);
}
}