diff --git a/include/class.ticket.php b/include/class.ticket.php
index 7b41282aed91167d827c1b8a93f005510873e99c..6518d12eae5722401bb1f96a4932ed00e14473c0 100644
--- a/include/class.ticket.php
+++ b/include/class.ticket.php
@@ -2218,7 +2218,8 @@ class Ticket {
             };
         };
 
-        $reject_ticket = function($message) use (&$errors, $ost) {
+        $reject_ticket = function($message) use (&$errors) {
+            global $ost;
             $errors = array(
                 'errno' => 403,
                 'err' => 'This help desk is for use by authorized users only');