From a72ff49f5a53d4a9a1a29a35070b319a10915cbd Mon Sep 17 00:00:00 2001
From: aydreeihn <adriane@enhancesoft.com>
Date: Wed, 2 May 2018 08:58:35 -0500
Subject: [PATCH] Quick Fix:

- On ticket edit, only display inactive help topic warning if the ticket has a help topic
---
 include/staff/ticket-edit.inc.php | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/include/staff/ticket-edit.inc.php b/include/staff/ticket-edit.inc.php
index f77e02b87..71d8871e6 100644
--- a/include/staff/ticket-edit.inc.php
+++ b/include/staff/ticket-edit.inc.php
@@ -94,8 +94,7 @@ if ($_POST)
                     <option value="" selected >&mdash; <?php echo __('Select Help Topic');?> &mdash;</option>
                     <?php
                     if($topics=Topic::getHelpTopics()) {
-                      if(!array_key_exists($ticket->topic_id, $topics))
-                      {
+                      if($ticket->topic_id && !array_key_exists($ticket->topic_id, $topics)) {
                         $topics[$ticket->topic_id] = $ticket->topic;
                         $warn = sprintf(__('%s selected must be active'), __('Help Topic'));
                       }
-- 
GitLab