From bb7022350943c6f049641d50d28cb99caf019b83 Mon Sep 17 00:00:00 2001 From: Mario Vavti Date: Fri, 13 Jul 2018 11:00:37 +0200 Subject: when calling timeago() from mod_mail.js it is called before the translations are applied - move the call to main.js and be more specific with the selector to not trigger calls for other modules (eg network) which is handled elsewhere to not be to much of an performance hog (to many dates at a time) --- view/js/main.js | 3 +++ view/js/mod_mail.js | 1 - 2 files changed, 3 insertions(+), 1 deletion(-) (limited to 'view/js') diff --git a/view/js/main.js b/view/js/main.js index 45c412296..17f94dd16 100644 --- a/view/js/main.js +++ b/view/js/main.js @@ -62,6 +62,9 @@ $(document).ready(function() { numbers : aStr['t17'], }; + //mod_mail only + $(".mail-conv-detail .autotime").timeago(); + savedTitle = document.title; updateInit(); diff --git a/view/js/mod_mail.js b/view/js/mod_mail.js index e3c891c2c..917e5414c 100644 --- a/view/js/mod_mail.js +++ b/view/js/mod_mail.js @@ -1,5 +1,4 @@ $(document).ready(function() { - $(".autotime").timeago(); $("#recip").name_autocomplete(baseurl + '/acl', 'm', false, function(data) { $("#recip-complete").val(data.xid); }); -- cgit v1.2.3