diff --git a/phpBB/adm/style/admin.js b/phpBB/adm/style/admin.js index f53329b5a7..f308bf9c12 100644 --- a/phpBB/adm/style/admin.js +++ b/phpBB/adm/style/admin.js @@ -291,12 +291,14 @@ function parse_document(container) const pageIconFont = document.getElementById('bbcode_font_icon'); - pageIconFont.addEventListener('keyup', function() { - updateIconClass(this.nextElementSibling, this.value); - }); + if (pageIconFont) { + pageIconFont.addEventListener('keyup', function () { + updateIconClass(this.nextElementSibling, this.value); + }); - pageIconFont.addEventListener('blur', function() { - updateIconClass(this.nextElementSibling, this.value); - }); + pageIconFont.addEventListener('blur', function () { + updateIconClass(this.nextElementSibling, this.value); + }); + } }); })(jQuery);