2
0

feat(user): Revokable API tokens

This commit is contained in:
Baptiste Arnaud
2022-06-03 13:20:19 +02:00
parent e5d7f1d1ce
commit a0929c492b
20 changed files with 472 additions and 43 deletions

View File

@ -123,17 +123,17 @@ export const timeSince = (date: string) => {
}
interval = seconds / 86400
if (interval > 1) {
return Math.floor(interval) + ' days'
return Math.floor(interval) + 'd'
}
interval = seconds / 3600
if (interval > 1) {
return Math.floor(interval) + ' hours'
return Math.floor(interval) + 'h'
}
interval = seconds / 60
if (interval > 1) {
return Math.floor(interval) + ' minutes'
return Math.floor(interval) + 'm'
}
return Math.floor(seconds) + ' seconds'
return Math.floor(seconds) + 's'
}
export const isCloudProdInstance = () =>