Skip to content

Commit

Permalink
web ui uptime fix
Browse files Browse the repository at this point in the history
  • Loading branch information
benjamin-wilson committed Sep 8, 2023
1 parent 9889b22 commit 712c670
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions main/http_server/axe-os/src/app/pipes/date-ago.pipe.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ export class DateAgoPipe implements PipeTransform {

transform(value: any, args?: any): any {
if (value) {
value = new Date().getTime() - value * 1000;
const seconds = Math.floor((+new Date() - +new Date(value)) / 1000);
if (seconds < 29) // less than 30 seconds ago will show as 'Just now'
return 'Just now';
Expand Down

0 comments on commit 712c670

Please sign in to comment.