diff --git a/source/js/next-boot.js b/source/js/next-boot.js index 2876313..c83a681 100644 --- a/source/js/next-boot.js +++ b/source/js/next-boot.js @@ -88,7 +88,7 @@ NexT.boot.refresh = function() { CONFIG.pangu && window.pangu.spacingPage(); CONFIG.exturl && NexT.utils.registerExtURL(); - CONFIG.copycode.enable && NexT.utils.registerCopyCode(); + NexT.utils.registerCopyCode(); NexT.utils.registerTabsTag(); NexT.utils.registerActiveMenuItem(); NexT.utils.registerLangSelect(); diff --git a/source/js/utils.js b/source/js/utils.js index 8f19cc5..696f396 100644 --- a/source/js/utils.js +++ b/source/js/utils.js @@ -70,6 +70,7 @@ NexT.utils = { span.classList.add(`hljs-${name}`); }); }); + if (!CONFIG.copycode.enable) return; element.insertAdjacentHTML('beforeend', '