Skip to content

Commit 7ab2cd6

Browse files
authored
[Pelias] Fix potential issue with nullable properties (#1256)
1 parent e33e1ea commit 7ab2cd6

File tree

2 files changed

+10
-4
lines changed

2 files changed

+10
-4
lines changed

src/Provider/Pelias/CHANGELOG.md

+6
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,12 @@
22

33
The change log describes what is "Added", "Removed", "Changed" or "Fixed" between each release.
44

5+
## 1.6.1
6+
7+
### Fixed
8+
9+
- Fix nullable properties
10+
511
## 1.6.0
612

713
### Added

src/Provider/Pelias/Model/PeliasAddress.php

+4-4
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ final class PeliasAddress extends Address
4040
private $name;
4141

4242
/**
43-
* @var float
43+
* @var float|null
4444
*/
4545
private $confidence;
4646

@@ -75,7 +75,7 @@ public function withSource(?string $source): self
7575
return $new;
7676
}
7777

78-
public function getLayer(): string
78+
public function getLayer(): ?string
7979
{
8080
return $this->layer;
8181
}
@@ -101,12 +101,12 @@ public function withName(?string $name): self
101101
return $new;
102102
}
103103

104-
public function getConfidence(): float
104+
public function getConfidence(): ?float
105105
{
106106
return $this->confidence;
107107
}
108108

109-
public function withConfidence(float $confidence): self
109+
public function withConfidence(?float $confidence): self
110110
{
111111
$new = clone $this;
112112
$new->confidence = $confidence;

0 commit comments

Comments
 (0)