fixes #4657
Merge pull request #4900 from dotCMS/issue-4657-js-error-in-console-in-design-template-screen

fixes #4657