'//www.your-cdn.com/image.jpg'
In other words don't specify http or https in the url, just do '//your-url.com/new.js'