From: ivan Date: Sat, 15 Oct 2005 13:37:22 +0000 (+0000) Subject: make sure config still works if no ticket system is configured... X-Git-Tag: BEFORE_FINAL_MASONIZE~353 X-Git-Url: http://git.freeside.biz/gitweb/?p=freeside.git;a=commitdiff_plain;h=ca5d0d84e05e1b9cea2b01107fc0a556bd98a62f make sure config still works if no ticket system is configured... --- diff --git a/FS/FS/Conf.pm b/FS/FS/Conf.pm index 5f2c3b355..75e1645a1 100644 --- a/FS/FS/Conf.pm +++ b/FS/FS/Conf.pm @@ -1476,11 +1476,20 @@ httemplate/docs/config.html 'type' => 'select-sub', 'options_sub' => sub { eval "use FS::TicketSystem;"; die $@ if $@; - FS::TicketSystem->queues(); + my $conf = new FS::Conf; + if ( $conf->config('ticket_system') ) { + FS::TicketSystem->queues(); + } else { + (); + } }, 'option_sub' => sub { eval "use FS::TicketSystem;"; die $@ if $@; - FS::TicketSystem->queue(shift); + if ( $conf->config('ticket_system') ) { + FS::TicketSystem->queue(shift); + } else { + ''; + } }, },