From 4cbaf6813181e96d8c91a26ad53a3afc4f0c40fc Mon Sep 17 00:00:00 2001 From: Yevhenii Kovalenko Date: Thu, 8 Feb 2024 14:00:25 +0100 Subject: [PATCH] Fixed: base_uri does not set correctly --- src/Client/Client.php | 2 +- src/Request/FindPointsRequest.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Client/Client.php b/src/Client/Client.php index 2f2dd4f..3943ea2 100644 --- a/src/Client/Client.php +++ b/src/Client/Client.php @@ -22,7 +22,7 @@ public function __construct( ) { $this->client = $client ?? new GuzzleClient( [ - 'base_uri' => $this->configProvider->baseUrl, + 'base_uri' => rtrim($this->configProvider->baseUrl, '/') . '/', ] ); } diff --git a/src/Request/FindPointsRequest.php b/src/Request/FindPointsRequest.php index 724098a..98db2c3 100644 --- a/src/Request/FindPointsRequest.php +++ b/src/Request/FindPointsRequest.php @@ -6,7 +6,7 @@ class FindPointsRequest implements Request { - private const ENDPOINT = '/points'; + private const ENDPOINT = 'points'; private const HTTP_METHOD = 'GET'; private array $searchCriteria;