Skip to content

Commit

Permalink
feat(date-time-utils): adding epoch time
Browse files Browse the repository at this point in the history
  • Loading branch information
kapdroid committed May 30, 2024
1 parent 475d6dd commit d2f682a
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions lib/src/utils/date_time_utils.dart
Original file line number Diff line number Diff line change
Expand Up @@ -231,6 +231,10 @@ class DateTimeUtils {
);
}
}

static int epochTime() {
return (DateTime.now().millisecondsSinceEpoch / 1000).toInt();
}
}

extension DateOnlyCompare on DateTime {
Expand Down

0 comments on commit d2f682a

Please sign in to comment.