summaryrefslogtreecommitdiffstats
path: root/core/src
diff options
context:
space:
mode:
authorJoas Schilling <coding@schilljs.com>2021-11-17 15:27:19 +0100
committerJoas Schilling <coding@schilljs.com>2022-01-14 11:28:26 +0100
commit0c4aa19c31ee9a81a3205e34f898375996d54098 (patch)
treea0ff8e4dca676454f5dddcae06f5e0ecf242866f /core/src
parent6a7b088adb95c2afb725cae7e02f1a39a153b2d9 (diff)
downloadnextcloud-server-0c4aa19c31ee9a81a3205e34f898375996d54098.tar.gz
nextcloud-server-0c4aa19c31ee9a81a3205e34f898375996d54098.zip
Don't use the deprecated method
Signed-off-by: Joas Schilling <coding@schilljs.com>
Diffstat (limited to 'core/src')
-rw-r--r--core/src/init.js3
1 files changed, 2 insertions, 1 deletions
diff --git a/core/src/init.js b/core/src/init.js
index 07cc5c87542..9f5bd6027ef 100644
--- a/core/src/init.js
+++ b/core/src/init.js
@@ -98,7 +98,8 @@ const initLiveTimestamps = () => {
// Update live timestamps every 30 seconds
setInterval(() => {
$('.live-relative-timestamp').each(function() {
- $(this).text(OC.Util.relativeModifiedDate(parseInt($(this).attr('data-timestamp'), 10)))
+ const timestamp = parseInt($(this).attr('data-timestamp'), 10)
+ $(this).text(moment(timestamp).fromNow())
})
}, 30 * 1000)
}