Skip to content

Commit 3739dae

Browse files
set zip instead of zone to narrow the search
1 parent e547490 commit 3739dae

File tree

2 files changed

+13
-1
lines changed

2 files changed

+13
-1
lines changed

src/Factory/Bpost/ServicePointQueryFactory.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ public function createServicePointQueryForAllPickupPoints(string $countryCode, ?
6565
$servicePointQuery->setCountry($countryCode);
6666

6767
if ($postalCode !== null) {
68-
$servicePointQuery->setZone($postalCode);
68+
$servicePointQuery->setZip($postalCode);
6969
}
7070

7171
return $servicePointQuery;

src/Model/Query/Bpost/ServicePointQuery.php

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,8 @@ final class ServicePointQuery implements ServicePointQueryInterface, CountryAwar
3838

3939
private int $limit;
4040

41+
private string $zip;
42+
4143
public function __construct(string $partner)
4244
{
4345
$this->checkData = 1;
@@ -217,6 +219,16 @@ public function setInfo(bool $info): void
217219
$this->info = $info;
218220
}
219221

222+
public function getZip(): string
223+
{
224+
return $this->zip;
225+
}
226+
227+
public function setZip(string $zip): void
228+
{
229+
$this->zip = $zip;
230+
}
231+
220232
public function toArray(): array
221233
{
222234
$arrayValue = [];

0 commit comments

Comments
 (0)