Skip to content

Commit d14d3e7

Browse files
committed
Remove model type capitalized words check
1 parent ae1c047 commit d14d3e7

1 file changed

Lines changed: 1 addition & 6 deletions

File tree

src/Model.php

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@
66
use JsonSerializable;
77
use Pace\XPath\Builder;
88
use Pace\Model\Attachments;
9-
use InvalidArgumentException;
109
use UnexpectedValueException;
1110

1211
class Model implements ArrayAccess, JsonSerializable
@@ -62,12 +61,8 @@ class Model implements ArrayAccess, JsonSerializable
6261
* @param string $type
6362
* @param array $attributes
6463
*/
65-
public function __construct(Client $client, $type, array $attributes = [])
64+
public function __construct(Client $client, string $type, array $attributes = [])
6665
{
67-
if (!preg_match('/^([A-Z]+[a-z]*)+$/', $type)) {
68-
throw new InvalidArgumentException('Type must be CapitalizedWords');
69-
}
70-
7166
$this->client = $client;
7267
$this->type = $type;
7368
$this->attributes = $attributes;

0 commit comments

Comments
 (0)