Skip to content

Commit

Permalink
#11 fix fatal error, not addon code
Browse files Browse the repository at this point in the history
  • Loading branch information
Jimmi08 committed Dec 9, 2024
1 parent 82286e9 commit 37f04b2
Showing 1 changed file with 12 additions and 4 deletions.
16 changes: 12 additions & 4 deletions helpdesk3/e_latest.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,17 @@
include_lan(e_PLUGIN . HELPDESK_FOLDER . "/languages/admin/" . e_LANGUAGE . ".php");
include_lan(e_PLUGIN . HELPDESK_FOLDER . "/languages/" . e_LANGUAGE . ".php");

$sql->db_Select("hdu_prefs");
$hdu_row = $sql->db_Fetch();
extract($hdu_row);
if (!isset($helpdesk_obj) || !is_object($helpdesk_obj))
{
require_once(e_PLUGIN . HELPDESK_FOLDER . "/includes/helpdesk_class.php");
$helpdesk_obj = new helpdesk;
}

$hduprefs_defaultres = $helpdesk_obj->hduprefs_defaultres;

// $sql->db_Select("hdu_prefs");
// $hdu_row = $sql->db_Fetch();
// extract($hdu_row);

$open_tickets = $sql->db_Count('hdunit', '(*)', "WHERE hdu_resolution='$hduprefs_defaultres' and hdu_closed=0");
if (empty($open_tickets))
Expand All @@ -18,5 +26,5 @@
$text .= HDU_197 . " " . $open_tickets;

$text .= '</div>';

//echo $text;
?>

0 comments on commit 37f04b2

Please sign in to comment.