diff --git a/files/templates/comments.html b/files/templates/comments.html index 62bd34ae77..d947c580c3 100644 --- a/files/templates/comments.html +++ b/files/templates/comments.html @@ -459,12 +459,12 @@ }; var clipboard = new ClipboardJS('.copy-link'); - clipboard.addEventListener('success', function(e) { + clipboard.on('success', function(e) { var myToast = new bootstrap.Toast(document.getElementById('toast-success')); myToast.show(); console.log(e); }); - clipboard.addEventListener('error', function(e) { + clipboard.on('error', function(e) { var myToast = new bootstrap.Toast(document.getElementById('toast-error')); myToast.show(); console.log(e); @@ -750,7 +750,7 @@ {% endif %}