From 7f2adf0383c85bb8d79cf6b321d125bef9a4c7f8 Mon Sep 17 00:00:00 2001 From: Justin Canton <67930245+JustinCanton@users.noreply.github.com> Date: Mon, 18 Sep 2023 21:29:51 -0400 Subject: [PATCH 1/2] fix(here): fixing an issue where the in parameter of the geocoding endpoint is not passed correctly (#87) (#89) * fix(here): fixing an issue where the in parameter of the geocoding endpoint is not passed correctly (#87) * build: adding hotfix branches to the pr build pipeline --- .github/workflows/dotnet-core.yml | 2 +- src/Geo.Here/Services/HereGeocoding.cs | 2 +- test/Geo.Here.Tests/Services/HereGeocodingShould.cs | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/dotnet-core.yml b/.github/workflows/dotnet-core.yml index a7550a4..ba99e7b 100644 --- a/.github/workflows/dotnet-core.yml +++ b/.github/workflows/dotnet-core.yml @@ -7,7 +7,7 @@ on: branches: - develop pull_request: - branches: [ master, develop, release/** ] + branches: [ master, develop, release/**, hotfix/** ] jobs: build: diff --git a/src/Geo.Here/Services/HereGeocoding.cs b/src/Geo.Here/Services/HereGeocoding.cs index fd560b2..195c3ca 100644 --- a/src/Geo.Here/Services/HereGeocoding.cs +++ b/src/Geo.Here/Services/HereGeocoding.cs @@ -185,7 +185,7 @@ internal Uri BuildGeocodingRequest(GeocodeParameters parameters) if (parameters.InCountry.Count > 0) { - query = query.Add("in", string.Join(",", parameters.InCountry.Select(x => x.ThreeLetterISORegionName))); + query = query.Add("in", $"countryCode:{string.Join(",", parameters.InCountry.Select(x => x.ThreeLetterISORegionName))}"); } else { diff --git a/test/Geo.Here.Tests/Services/HereGeocodingShould.cs b/test/Geo.Here.Tests/Services/HereGeocodingShould.cs index 5b2aa3a..5e78243 100644 --- a/test/Geo.Here.Tests/Services/HereGeocodingShould.cs +++ b/test/Geo.Here.Tests/Services/HereGeocodingShould.cs @@ -673,7 +673,7 @@ public void BuildGeocodingRequestSuccessfully(CultureInfo culture) var query = HttpUtility.UrlDecode(uri.PathAndQuery); query.Should().Contain("q=123 East"); query.Should().Contain("qq=123 West"); - query.Should().Contain("in=DNK,JPN,SRB"); + query.Should().Contain("in=countryCode:DNK,JPN,SRB"); query.Should().Contain("at=56.789,123.456"); query.Should().Contain("types=address,area"); query.Should().Contain("limit=91"); From 9aa7d1798d3f086f2481a8cf220d769167982b63 Mon Sep 17 00:00:00 2001 From: JustinCanton <67930245+JustinCanton@users.noreply.github.com> Date: Mon, 18 Sep 2023 21:32:37 -0400 Subject: [PATCH 2/2] docs: updating the changelog --- CHANGELOG.md | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index c450e1a..05bbe3a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,11 @@ All notable changes to this project will be documented in this file. See [Conventional Commits](https://conventionalcommits.org/) for commit guidelines. +## [1.5.2](https://github.com/JustinCanton/Geo.NET/compare/1.5.1...1.5.2) (2023-09-18) +### Bug Fixes +- **here**: fixing an issue where the in parameter of the geocoding endpoint is not passed correctly ([#87](https://github.com/JustinCanton/Geo.NET/issues/87)) ([7f2adf0](https://github.com/JustinCanton/Geo.NET/commit/7f2adf0383c85bb8d79cf6b321d125bef9a4c7f8)) + + ## [1.5.1](https://github.com/JustinCanton/Geo.NET/compare/1.5.0...1.5.1) (2023-09-01) ### Features - **mapbox**: adding the new worldview parameter to the forward and reverse geocode parameters ([#77](https://github.com/JustinCanton/Geo.NET/issues/77)) ([cfc987c](https://github.com/JustinCanton/Geo.NET/commit/cfc987cc1f7db2e5d0a7e3981f3a0c4325d2211b))