Title: Combine JavaScript Files breaks Header Image
Last modified: June 23, 2020

---

# Combine JavaScript Files breaks Header Image

 *  Resolved [andybritnell](https://wordpress.org/support/users/andybritnell/)
 * (@andybritnell)
 * [5 years, 11 months ago](https://wordpress.org/support/topic/combine-javascript-files-breaks-header-image/)
 * Hi There
 * I have a Uncode Theme which uses Content Blocks to populate the header in pages.
 * The plugin works fine in all aspects except for Combine JavaScript Files. When
   I enable this the images on the header do not show up. Just the title with a 
   black background. I’ve tried excluding the content block url and the Image itself
   but that doesn’t work even though the test shows it as not cached.
 * It looks fine if you view the site via WordPress admin but on the live site it
   is broken.
 * Any ideas on how to rectify this. It’s killing my load time on Mobile and Core
   web vitals show all my urls are poor!
 * I’ve not activated Combine JavaScript Files at the moment because the visitor
   experience is poor with it on.
 * Many thanks
 * Andy
 * The page I need help with: _[[log in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fwordpress.org%2Fsupport%2Ftopic%2Fcombine-javascript-files-breaks-header-image%2F%3Foutput_format%3Dmd&locale=en_US)
   to see the link]_

Viewing 14 replies - 1 through 14 (of 14 total)

 *  Plugin Author [Stanimir Stoyanov](https://wordpress.org/support/users/sstoqnov/)
 * (@sstoqnov)
 * SiteGround Representative
 * [5 years, 11 months ago](https://wordpress.org/support/topic/combine-javascript-files-breaks-header-image/#post-13023809)
 * Hey [@andybritnell](https://wordpress.org/support/users/andybritnell/)
 * It’s a known issue between SG Optimizer and Undsgn themes/plugins.
 * We are currently working on it, and we will try to include a fix in the upcoming
   version.
 * Meanwhile, please keep Combine JS disabled.
 * Regards,
    Stanimir
 *  Thread Starter [andybritnell](https://wordpress.org/support/users/andybritnell/)
 * (@andybritnell)
 * [5 years, 11 months ago](https://wordpress.org/support/topic/combine-javascript-files-breaks-header-image/#post-13024140)
 * Hi Stanimir
 * Ok thanks for that information – looking forward to getting a fix on it 🙂
 * Best wishes
 * Andy
 *  Plugin Author [Stanimir Stoyanov](https://wordpress.org/support/users/sstoqnov/)
 * (@sstoqnov)
 * SiteGround Representative
 * [5 years, 10 months ago](https://wordpress.org/support/topic/combine-javascript-files-breaks-header-image/#post-13098509)
 * Hey [@andybritnell](https://wordpress.org/support/users/andybritnell/)
 * We’ve fixed everything related to our plugin, and we will release a new version
   soon. I think that the JS combination will work for sites using Uncode themes.
 * But, there is one small thing that you should request from Uncode team to address:
 * They should change the following condition:
    `if ( elem !== null && typeof elem.
   classList !== 'undefined' )`
 * TO:
    `if ( elem !== undefined && typeof elem.classList !== 'undefined' )`
 * Because if an element doesn’t exist, it will return `undefined` instead of `null`.
 * Regards,
    Stanimir
 *  Thread Starter [andybritnell](https://wordpress.org/support/users/andybritnell/)
 * (@andybritnell)
 * [5 years, 10 months ago](https://wordpress.org/support/topic/combine-javascript-files-breaks-header-image/#post-13099712)
 * Hi Stanimir
 * My ‘helpful’ Uncode team came back with this!
 * Hi Andy,
 * You have to do yourself and ask them clear instructions where to change or hire
   a developer who can do this for you.
    Imran | Undsgn™ Support
 * So can you let me know where specifically I change this code and if I need to
   wait for the fix before changing it.
 * Many thanks
 * Andy
 *  Plugin Author [Stanimir Stoyanov](https://wordpress.org/support/users/sstoqnov/)
 * (@sstoqnov)
 * SiteGround Representative
 * [5 years, 10 months ago](https://wordpress.org/support/topic/combine-javascript-files-breaks-header-image/#post-13099737)
 * Hey [@andybritnell](https://wordpress.org/support/users/andybritnell/)
 * They should change the line I mentioned in my previous reply in themes/uncode/
   library/js/unit.js on line 565, 568, 571, 575, 579, and 583.
 * Hope this will help 🙂
 * Regards,
    Stanimir
 *  Thread Starter [andybritnell](https://wordpress.org/support/users/andybritnell/)
 * (@andybritnell)
 * [5 years, 10 months ago](https://wordpress.org/support/topic/combine-javascript-files-breaks-header-image/#post-13099750)
 * Hi Stanimir
 * OK – thanks for the info – I’ll hold back until you update the plugin and then
   make the change.
 * Many thanks
 * Andy
 *  Plugin Author [Stanimir Stoyanov](https://wordpress.org/support/users/sstoqnov/)
 * (@sstoqnov)
 * SiteGround Representative
 * [5 years, 10 months ago](https://wordpress.org/support/topic/combine-javascript-files-breaks-header-image/#post-13099752)
 * Hey [@andybritnell](https://wordpress.org/support/users/andybritnell/)
 * We’ve released a new version few seconds ago 🙂
 * Regards,
    Stanimir
 *  Thread Starter [andybritnell](https://wordpress.org/support/users/andybritnell/)
 * (@andybritnell)
 * [5 years, 10 months ago](https://wordpress.org/support/topic/combine-javascript-files-breaks-header-image/#post-13099762)
 * Ok Cool
 * Just updating it now.
 * Will let you know if it fixes thngs 🙂
 * Bets wishes
 * Andy
 *  Plugin Author [Stanimir Stoyanov](https://wordpress.org/support/users/sstoqnov/)
 * (@sstoqnov)
 * SiteGround Representative
 * [5 years, 10 months ago](https://wordpress.org/support/topic/combine-javascript-files-breaks-header-image/#post-13099769)
 * Please note that the file init.js is minified when the Uncode team release a 
   new version and the minified copy is located in themes/uncode/library/js/min/
   unit.min.js
 *  Thread Starter [andybritnell](https://wordpress.org/support/users/andybritnell/)
 * (@andybritnell)
 * [5 years, 10 months ago](https://wordpress.org/support/topic/combine-javascript-files-breaks-header-image/#post-13099783)
 * Hi Stanimir
 * I checked the site without updating code and it’s working without changing any
   code so good work from your team fixing that.
 * You can check it out at [https://www.dennismaps.co.uk/](https://www.dennismaps.co.uk/)
 * Full marks for problem solving and customer service.
 * Best wishes
 * Andy
 *  Thread Starter [andybritnell](https://wordpress.org/support/users/andybritnell/)
 * (@andybritnell)
 * [5 years, 10 months ago](https://wordpress.org/support/topic/combine-javascript-files-breaks-header-image/#post-13099905)
 * Hi Stanimir
 * Does that mean even though it works I still need to make the code changes?
 * Many thanks
 * Andy
 *  Plugin Author [Stanimir Stoyanov](https://wordpress.org/support/users/sstoqnov/)
 * (@sstoqnov)
 * SiteGround Representative
 * [5 years, 10 months ago](https://wordpress.org/support/topic/combine-javascript-files-breaks-header-image/#post-13099972)
 * Hey [@andybritnell](https://wordpress.org/support/users/andybritnell/),
 * Well, there is an error in the console, which doesn’t break the site or its functionality,
   but it will be nice if the Uncode team fixes their code.
 * I do not recommend making changes of plugins/themes because when a new version
   is released, everything will be removed after an update.
 * Regards,
    Stanimir
 *  Thread Starter [andybritnell](https://wordpress.org/support/users/andybritnell/)
 * (@andybritnell)
 * [5 years, 10 months ago](https://wordpress.org/support/topic/combine-javascript-files-breaks-header-image/#post-13100123)
 * Hi Stanimir
 * Agreed they really should pull there finger out a bit more! (English idiom)
 * I’m happy with this now as it’s significantly improved load speed.
 * Left you a 5* review as you’ve been so helpful.
 * Best wishes
 * Andy
 *  Plugin Author [Stanimir Stoyanov](https://wordpress.org/support/users/sstoqnov/)
 * (@sstoqnov)
 * SiteGround Representative
 * [5 years, 10 months ago](https://wordpress.org/support/topic/combine-javascript-files-breaks-header-image/#post-13100151)
 * Thank you for the kind words 🙂

Viewing 14 replies - 1 through 14 (of 14 total)

The topic ‘Combine JavaScript Files breaks Header Image’ is closed to new replies.

 * ![](https://ps.w.org/sg-cachepress/assets/icon-256x256.gif?rev=2971889)
 * [Speed Optimizer - The All-In-One Performance-Boosting Plugin](https://wordpress.org/plugins/sg-cachepress/)
 * [Support Threads](https://wordpress.org/support/plugin/sg-cachepress/)
 * [Active Topics](https://wordpress.org/support/plugin/sg-cachepress/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/sg-cachepress/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/sg-cachepress/reviews/)

## Tags

 * [header](https://wordpress.org/support/topic-tag/header/)
 * [uncode](https://wordpress.org/support/topic-tag/uncode/)

 * 14 replies
 * 2 participants
 * Last reply from: [Stanimir Stoyanov](https://wordpress.org/support/users/sstoqnov/)
 * Last activity: [5 years, 10 months ago](https://wordpress.org/support/topic/combine-javascript-files-breaks-header-image/#post-13100151)
 * Status: resolved