From 2487e70d1fa40cdfa2a8d0eca1bcc3ca9d1170cc Mon Sep 17 00:00:00 2001 From: Mark Wells Date: Mon, 29 Apr 2013 23:53:20 -0700 Subject: [PATCH] allow selfservice to remove service address, #20716 --- FS/FS/ClientAPI/MyAccount.pm | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/FS/FS/ClientAPI/MyAccount.pm b/FS/FS/ClientAPI/MyAccount.pm index be87e594e..d946a6239 100644 --- a/FS/FS/ClientAPI/MyAccount.pm +++ b/FS/FS/ClientAPI/MyAccount.pm @@ -704,6 +704,14 @@ sub edit_info { $new->set( $_ => $p->{$_} ) foreach grep { exists $p->{$_} } @cust_main_editable_fields; + if ( $new->ship_address1 eq '' ) { + # then the ship address is being set to null + $new->set($_ => '') + foreach qw(ship_longitude ship_latitude ship_coord_auto ship_mobile); + } + + + my $payby = ''; if (exists($p->{'payby'})) { $p->{'payby'} =~ /^([A-Z]{4})$/ -- 2.20.1