Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save briantully/800482 to your computer and use it in GitHub Desktop.
Save briantully/800482 to your computer and use it in GitHub Desktop.
From bdc3919fd8cccde0c59f4849bc8950c8f3e983ba Mon Sep 17 00:00:00 2001
From: Brian Tully <btully@about.com>
Date: Thu, 27 Jan 2011 15:14:09 -0500
Subject: [PATCH] re #2366: No ads on PLP due to javascript error
---
.../google_afs_widget/google_afs_widget_retry.js | 3 +++
.../google_afs_widget_retry_check.js | 3 +++
2 files changed, 6 insertions(+), 0 deletions(-)
diff --git a/src/sites/all/modules/csearch/adwidget/widgets/google_afs_widget/google_afs_widget_retry.js b/src/sites/all/modules/csearch/adwidget/widgets/google_afs_widget/google_afs_widget_retry.js
index 3c74e33..5bec1b9 100644
--- a/src/sites/all/modules/csearch/adwidget/widgets/google_afs_widget/google_afs_widget_retry.js
+++ b/src/sites/all/modules/csearch/adwidget/widgets/google_afs_widget/google_afs_widget_retry.js
@@ -1,5 +1,8 @@
if (Drupal.jsEnabled) {
+ var settings = Drupal.settings.google_afs_widget;
+ if (settings == undefined) return;
+
// The global "google_afs_widget_no_retry" is not set in "google_afs_widget_callback.js"
// if the function "google_afs_request_done()" is NOT called.
// Therefore retry the retrieve of Google AFS ads if it is not set.
diff --git a/src/sites/all/modules/csearch/adwidget/widgets/google_afs_widget/google_afs_widget_retry_check.js b/src/sites/all/modules/csearch/adwidget/widgets/google_afs_widget/google_afs_widget_retry_check.js
index 955d8cd..8ad278d 100644
--- a/src/sites/all/modules/csearch/adwidget/widgets/google_afs_widget/google_afs_widget_retry_check.js
+++ b/src/sites/all/modules/csearch/adwidget/widgets/google_afs_widget/google_afs_widget_retry_check.js
@@ -1,5 +1,8 @@
if (Drupal.jsEnabled) {
+ var settings = Drupal.settings.google_afs_widget;
+ if (settings == undefined) return;
+
// The global "google_afs_widget_no_retry" is not set in "google_afs_widget_callback.js"
// if the function "google_afs_request_done()" is NOT called.
// Therefore retry the retrieve of Google AFS ads if it is not set.
--
1.7.3.1+GitX
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment