SyntaxFix
Write A Post
Hire A Developer
Questions
Another option is to use the TimeUtils utility method:
TimeUtils
TimeUtils.millisToUnit(System.currentTimeMillis(), TimeUnit.SECONDS)