From 3032b8c500116a94d847ab8e82430b985f5bd868 Mon Sep 17 00:00:00 2001 From: erickson Date: Mon, 25 Jul 2005 00:52:22 +0000 Subject: [PATCH] made it so it doesn't complain about not having any apps to load git-svn-id: svn://svn.open-ils.org/OpenSRF/trunk@420 9efc2488-bf62-4759-914b-345cdb29e865 --- src/perlmods/OpenSRF/System.pm | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/src/perlmods/OpenSRF/System.pm b/src/perlmods/OpenSRF/System.pm index f932d73..eea252b 100644 --- a/src/perlmods/OpenSRF/System.pm +++ b/src/perlmods/OpenSRF/System.pm @@ -145,6 +145,11 @@ sub bootstrap { my $apps = $client->config_value("activeapps", "appname"); if(!ref($apps) eq "ARRAY") { $apps = [$apps]; } + if(@$apps == 0) { + print "No apps to load, exiting..."; + return; + } + for my $app (@$apps) { # verify we are a settings server and launch if( $app eq "opensrf.settings" ) { @@ -161,6 +166,12 @@ sub bootstrap { my $client = OpenSRF::Utils::SettingsClient->new(); my $apps = $client->config_value("activeapps", "appname" ); if(!ref($apps)) { $apps = [$apps]; } + + if(@$apps == 0) { + print "No apps to load, exiting..."; + return; + } + my $server_type = $client->config_value("server_type"); $server_type ||= "basic"; @@ -349,6 +360,8 @@ sub launch_listener { foreach my $app ( @$apps ) { + next unless defined($app); + if( $app eq "opensrf.settings" ) { next; } _log( " * Starting Listener for $app..." ); -- 2.11.0