Fix Google Optimize loading on request pages
Fix Google Optimize loading on request pages

Fix for two mistakes in 636b881:

1. Makes sure that `dataLayer` is defined at pageload.
2. Avoids calling `ga('send', 'pageview')` twice.

Also, the `content_for :ga_pageview` block is now defined *before* the
`render partial => 'ga_events'` block so our `ga` `create/require/send`
calls are in the same order that the docs[^1] recommend. I don‘t think
it makes a difference whether the pageview is sent before or after the
Optimize ID is included, but at least this way it matches the docs.

[1]: https://support.google.com/optimize/answer/6262084

mysociety/whatdotheyknow-theme,mysociety/whatdotheyknow-theme,mysociety/whatdotheyknow-theme