Skip to content

Commit

Permalink
Don't allow duplicates
Browse files Browse the repository at this point in the history
  • Loading branch information
dwilkie committed Nov 3, 2024
1 parent 1c43702 commit 633133c
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 19 deletions.
4 changes: 0 additions & 4 deletions data/cities/us/ga.json
Original file line number Diff line number Diff line change
Expand Up @@ -9496,10 +9496,6 @@
"name": "CHATAHOCHE",
"distance_km": 15.55
},
{
"name": "CHATAHOCHE",
"distance_km": 15.55
},
{
"name": "REYNOLDSVL",
"distance_km": 17.65
Expand Down
15 changes: 0 additions & 15 deletions data/rate_centers/us/ga.json
Original file line number Diff line number Diff line change
Expand Up @@ -2400,21 +2400,6 @@
"distance_km": 15.55
}
},
{
"country": "US",
"region": "GA",
"exchange": "032980",
"name": "CHATAHOCHE",
"full_name": "Chattahoochee",
"lata": "450",
"ilec_name": "CONSOLIDATED COMMUNICATIONS OF FLORIDA COMPANY",
"lat": "30.716717",
"long": "-84.794117",
"closest_city": {
"name": "Faceville",
"distance_km": 15.55
}
},
{
"country": "US",
"region": "GA",
Expand Down
2 changes: 2 additions & 0 deletions lib/rate_center/data_source/local_calling_guide.rb
Original file line number Diff line number Diff line change
Expand Up @@ -97,6 +97,8 @@ def load_data!(**options)
SPECIAL_CASE_LATAS.select { |lata| lata.region == region }.each do |lata|
rate_centers.concat(client.fetch_rate_center_data(region:, lata: lata.code).data)
end
rate_centers.uniq!(&:exch)

next if rate_centers.empty?

data = rate_centers.sort_by { |rc| [ (rc.rcshort || rc.rc), rc.exch ] }.map do |rate_center|
Expand Down

0 comments on commit 633133c

Please sign in to comment.