-% if ( $new{error} or $new{ship_error} ) {
+% if ( $new{bill_error} or $new{ship_error} ) {
Address standardization error
% }
% else {
@@ -15,11 +15,11 @@ Confirm address standardization
% if ( $old{onlyship} ) {
% @prefixes = ('ship_');
% } elsif ( $old{same} ) {
-% @prefixes = ('');
+% @prefixes = ('bill_');
% } else {
-% @prefixes = ('', 'ship_');
+% @prefixes = ('bill_', 'ship_');
% }
-% for my $pre ('', 'ship_') {
+% for my $pre (@prefixes) {
% my $name = $pre eq 'ship_' ? 'service' : 'billing';
% if ( $new{$pre.'addr_clean'} ) {
@@ -70,24 +70,27 @@ Confirm address standardization
% } # for $pre
%# only do this part if address standardization provided a censustract
-% if ( $new{'ship_censustract'} ) {
+% my $pre = $old{same} ? 'bill_' : 'ship_';
+% my $censustract = $new{$pre.'censustract'};
+% my $census_error = $new{$pre.'census_error'};
+% if ( $censustract ) {