Sfoglia il codice sorgente

Fix google analytics

poeti8 6 anni fa
parent
commit
1cf87f6681

+ 1 - 1
client/components/BodyWrapper/BodyWrapper.js

@@ -42,7 +42,7 @@ const ContentWrapper = styled.div`
 
 class BodyWrapper extends React.Component {
   componentDidMount() {
-    if (process.env.GOOGLE_ANALYTICS_ID) {
+    if (process.env.GOOGLE_ANALYTICS) {
       if (!window.GA_INITIALIZED) {
         initGA();
         window.GA_INITIALIZED = true;

+ 1 - 1
client/helpers/analytics.js

@@ -1,7 +1,7 @@
 import ReactGA from 'react-ga';
 
 export const initGA = () => {
-  ReactGA.initialize(process.env.GOOGLE_ANALYTICS_ID);
+  ReactGA.initialize(process.env.GOOGLE_ANALYTICS);
 };
 
 export const logPageView = () => {