From: rsiddall Date: Sat, 16 May 2009 19:29:31 +0000 (+0000) Subject: Defer loading Net::OpenSRS so that failure to install this module doesn't X-Git-Tag: freeside_1_7_4rc1~34 X-Git-Url: http://git.freeside.biz/gitweb/?a=commitdiff_plain;h=d05137f0c77747d3f69bcb1b9557a592855d2297;p=freeside.git Defer loading Net::OpenSRS so that failure to install this module doesn't stop Apache from starting. This will cause attempts to register domains to fail instead. --- diff --git a/FS/FS/part_export/domreg_opensrs.pm b/FS/FS/part_export/domreg_opensrs.pm index 5d5c59530..df8b40006 100644 --- a/FS/FS/part_export/domreg_opensrs.pm +++ b/FS/FS/part_export/domreg_opensrs.pm @@ -7,7 +7,6 @@ use FS::Conf; use FS::part_export::null; use FS::svc_domain; use FS::part_pkg; -use Net::OpenSRS; =head1 NAME @@ -193,6 +192,9 @@ sub _export_insert { return if $svc_domain->action eq 'I'; # Ignoring registration, just doing DNS + eval "use Net::OpenSRS;"; + return $@ if $@; + # Get the TLD of the new domain my @bits = split /\./, $svc_domain->domain;