fixes ga.js and improves compatibility with newer Pelican