Use embedded address location rather than external location on geocode

This commit is contained in:
Eli Ribble 2026-04-14 01:32:32 +00:00
parent 3c62fe2ca1
commit cadf6afb5f
No known key found for this signature in database
6 changed files with 22 additions and 23 deletions

View file

@ -40,6 +40,7 @@ func ByGID(ctx context.Context, gid string) (*GeocodeResult, error) {
GID: feature.Properties.GID,
ID: &id,
Locality: feature.Properties.Context.WhosOnFirst.Locality.Name,
Location: &location,
Number: feature.Properties.AddressComponents.Number,
PostalCode: feature.Properties.AddressComponents.PostalCode,
Raw: feature.Properties.FormattedAddressLine,
@ -47,7 +48,6 @@ func ByGID(ctx context.Context, gid string) (*GeocodeResult, error) {
Street: feature.Properties.AddressComponents.Street,
Unit: "",
},
Cell: cell,
Location: location,
Cell: cell,
}, nil
}