mirror of
https://github.com/osm-search/Nominatim.git
synced 2026-02-16 15:47:58 +00:00
merge linked names correctly into namedetails
Convert the '_place_*' entries back to normal entries before returning them in the 'namedetails' section. If the name field is duplicated, kept the '_place_*' notation. This preserves the previous behaviour before _place_ names were introduces but adds the additional names from the linked place for reference.
This commit is contained in:
@@ -17,9 +17,11 @@ Feature: Searching linked places
|
||||
| object | linked_place_id |
|
||||
| N2 | R13 |
|
||||
When sending search query "Vario"
|
||||
| namedetails |
|
||||
| 1 |
|
||||
Then results contain
|
||||
| osm | display_name |
|
||||
| R13 | Garbo |
|
||||
| osm | display_name | namedetails |
|
||||
| R13 | Garbo | "name": "Garbo", "name:it": "Vario" |
|
||||
When sending search query "Vario"
|
||||
| accept-language |
|
||||
| it |
|
||||
@@ -43,9 +45,11 @@ Feature: Searching linked places
|
||||
| object | linked_place_id |
|
||||
| N2 | R13 |
|
||||
When sending search query "Vario"
|
||||
| namedetails |
|
||||
| 1 |
|
||||
Then results contain
|
||||
| osm | display_name |
|
||||
| R13 | Garbo |
|
||||
| osm | display_name | namedetails |
|
||||
| R13 | Garbo | "name": "Garbo", "_place_name": "Vario" |
|
||||
When sending search query "Garbo"
|
||||
Then results contain
|
||||
| osm | display_name |
|
||||
|
||||
Reference in New Issue
Block a user