diff --git a/files/assets/js/comments_v.js b/files/assets/js/comments_v.js index f36ad93fb..acc8e586c 100644 --- a/files/assets/js/comments_v.js +++ b/files/assets/js/comments_v.js @@ -264,7 +264,7 @@ function post_comment(fullname, hide){ document.onpaste = function(event) { var focused = document.activeElement; - const files = event.clipboardData.files + const files = structuredClone(event.clipboardData.files); if (files.length > 4) { diff --git a/files/assets/js/settings_profile.js b/files/assets/js/settings_profile.js index bbe6f1e99..bbc2d5ee8 100644 --- a/files/assets/js/settings_profile.js +++ b/files/assets/js/settings_profile.js @@ -87,7 +87,7 @@ function updatebgselection(){ document.onpaste = function(event) { var focused = document.activeElement; if (focused.id == 'bio-text') { - const files = event.clipboardData.files + const files = structuredClone(event.clipboardData.files); if (files.length > 4) { diff --git a/files/assets/js/submit.js b/files/assets/js/submit.js index 8dd91e444..bc35d697d 100644 --- a/files/assets/js/submit.js +++ b/files/assets/js/submit.js @@ -55,7 +55,7 @@ function hide_image() { } document.onpaste = function(event) { - files = event.clipboardData.files + files = structuredClone(event.clipboardData.files); if (files.length > 4) { diff --git a/files/templates/submit_hats.html b/files/templates/submit_hats.html index 5a5245a45..75b674e2e 100644 --- a/files/templates/submit_hats.html +++ b/files/templates/submit_hats.html @@ -74,7 +74,7 @@