aboutsummaryrefslogtreecommitdiff
path: root/src/Entities/CountryEntity.php
diff options
context:
space:
mode:
authorValentin Popov <info@valentineus.link>2020-07-19 18:48:41 +0300
committerValentin Popov <info@valentineus.link>2020-07-19 18:48:41 +0300
commit400862f5eea453730b556b34faf1bb45b03a6751 (patch)
treeddc6b75536a9119102dc48762125225a6d6b4ec0 /src/Entities/CountryEntity.php
parent915cd7b1e0f0f1f994fddafdacfea8f649ff2fa9 (diff)
downloadphp-epg-service-400862f5eea453730b556b34faf1bb45b03a6751.tar.xz
php-epg-service-400862f5eea453730b556b34faf1bb45b03a6751.zip
Updated country entity
Signed-off-by: Valentin Popov <info@valentineus.link>
Diffstat (limited to 'src/Entities/CountryEntity.php')
-rw-r--r--src/Entities/CountryEntity.php7
1 files changed, 3 insertions, 4 deletions
diff --git a/src/Entities/CountryEntity.php b/src/Entities/CountryEntity.php
index fb559d8..37d4d6e 100644
--- a/src/Entities/CountryEntity.php
+++ b/src/Entities/CountryEntity.php
@@ -20,7 +20,6 @@ declare(strict_types = 1);
namespace EPGService\Entities;
use RuntimeException;
-use function is_int;
use function is_string;
/**
@@ -36,9 +35,9 @@ use function is_string;
*/
final class CountryEntity {
/**
- * @var int
+ * @var string
*/
- private int $id;
+ private string $id;
/**
* @var string
@@ -79,7 +78,7 @@ final class CountryEntity {
* @throws \RuntimeException
*/
public static function create(array $payload): CountryEntity {
- if (!is_int($payload['id'])) {
+ if (!is_string($payload['id'])) {
throw new RuntimeException('blah-blah-blah');
}