From 077da0c7758c72a2c8b1991997e844edb5e167ff Mon Sep 17 00:00:00 2001 From: Eduardo Cereto Carvalho Date: Mon, 19 Nov 2012 13:34:23 -0800 Subject: [PATCH] check if _gat exists before including ga.js MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This is supposed to allow users to use dc.js with gas. They should include the dc.js file synchronously before the _gas codeĀ  snippet. --- src/wrapup.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/wrapup.js b/src/wrapup.js index 3879934..f5ebd51 100755 --- a/src/wrapup.js +++ b/src/wrapup.js @@ -7,7 +7,7 @@ while (_gas._queue.length > 0) { } // Import ga.js -if (_gaq && _gaq.length >= 0) { +if (typeof window._gat === 'undefined') { (function () { var ga = document.createElement('script'); ga.type = 'text/javascript';