Skip to content

Commit b9d80e1

Browse files
committed
update Date extensions
1 parent a2e8726 commit b9d80e1

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

common/src/main/scala/app/softnetwork/time/package.scala

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ package object time {
1515
def toLocalDate: LocalDate = d
1616
def toLocalDateTime: LocalDateTime = d
1717
def toZonedDateTime: ZonedDateTime = d
18+
def toEpochSecond: Long = d.toInstant.getEpochSecond
1819
}
1920

2021
implicit def epochSecondToInstant(epochSecond: Long): Instant = {

0 commit comments

Comments
 (0)