summaryrefslogtreecommitdiff
path: root/FS
diff options
context:
space:
mode:
Diffstat (limited to 'FS')
-rw-r--r--FS/FS/part_export/http_status.pm14
1 files changed, 11 insertions, 3 deletions
diff --git a/FS/FS/part_export/http_status.pm b/FS/FS/part_export/http_status.pm
index 80139e776..5c4a8d074 100644
--- a/FS/FS/part_export/http_status.pm
+++ b/FS/FS/part_export/http_status.pm
@@ -129,7 +129,7 @@ sub export_setstatus_listdel {
}
sub export_setstatus_listX {
- my( $self, $svc_x, $action, $list, $address ) = @_;
+ my( $self, $svc_x, $action, $list, $address_item ) = @_;
my $option;
if ( $list =~ /^[WA]/i ) { #Whitelist/Allow
@@ -139,8 +139,16 @@ sub export_setstatus_listX {
}
$option .= $action. '_url';
- $address = Email::Valid->address($address)
- or die "address failed $Email::Valid::Details check.\n";
+ my $address;
+ unless ( $address = Email::Valid->address($address_item) ) {
+
+ if ( $address_item =~ /^(\@[\w\-\.]+\.\w{2,63})$/ ) { # "@domain"
+ $address = $1;
+ } else {
+ die "address failed $Email::Valid::Details check.\n";
+ }
+
+ }
#some false laziness w/export_getstatus above
my $url;