From 257310411680fa523d1787d98fcb462c9d5776ab Mon Sep 17 00:00:00 2001
From: Christopher Gervais <chris@ergonlogic.com>
Date: Mon, 12 Sep 2011 13:46:01 -0400
Subject: [PATCH] Issue #1271038 by ergonlogic: Limiting 'no client' error message display to certain paths.

---
 support.module |    5 ++++-
 1 files changed, 4 insertions(+), 1 deletions(-)

diff --git a/support.module b/support.module
index b3ea565..450481f 100644
--- a/support.module
+++ b/support.module
@@ -2531,7 +2531,10 @@ function _support_available_clients($account = NULL) {
       }
     }
     else {
-      drupal_set_message(t('There are no support clients configured/enabled.'), 'error', FALSE);
+      if (arg(0) == 'admin' && arg(1) == 'support' || arg(0) == 'support' || (arg(0) == 'node' && arg(1) == 'add' && arg(2) == 'support-ticket')) {
+        drupal_set_message(t('There are no support clients configured/enabled.'), 'error', FALSE);
+      }
+      watchdog('support', t('There are no support clients configured/enabled.'), NULL, WATCHDOG_WARNING, l(t('Add client'), 'admin/support/clients/add'));
     }
   }
   return isset($valid[$account->uid]) ? $valid[$account->uid] : NULL;
-- 
1.7.4.1

