Skip to content

Commit

Permalink
Better fix for the N CENTER ST search
Browse files Browse the repository at this point in the history
  • Loading branch information
nigelhorne committed Mar 27, 2018
1 parent b95807c commit 3f71ee3
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions createdatabase.PL
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,7 @@ if(my $oa = $ENV{'OPENADDR_HOME'}) {
# next unless($csv_file =~ /statewide/);
# next unless($csv_file =~ /us\/ne\/dawes/);
# next unless($csv_file =~ /us\/ca\/sonoma/);
# next unless($csv_file =~ /us\/md\/frederick/);
# next unless($csv_file =~ /us\/md\/statewide/);

# Handle https://github.com/openaddresses/openaddresses/issues/3928
# TODO: It would be better to merge airdrie.csv and city_of_airdrie.csv
Expand Down Expand Up @@ -654,7 +654,8 @@ sub insert {
# All of the place's values are combined into one large INSERT INTO
$queued_commits{$digest} = $columns;

if($columns->{'STREET'} && ($columns->{'STREET'} =~ /\s/)) {
if($columns->{'STREET'} && ($columns->{'STREET'} =~ /\s\w+\s/)) {
# Handle https://rt.cpan.org/Public/Bug/Display.html?id=124919
my $s = $columns->{'STREET'}; # Should use a 'local' variable I guess
$columns->{'STREET'} =~ s/\s+//g;
$digest = '';
Expand Down

0 comments on commit 3f71ee3

Please sign in to comment.