Skip to content

Commit

Permalink
Issue facebookarchive#335 Allow constant getter to accept integers as…
Browse files Browse the repository at this point in the history
… well as strings
  • Loading branch information
m4olivei committed Aug 22, 2018
1 parent db20430 commit 6e6c163
Showing 1 changed file with 4 additions and 1 deletion.
Expand Up @@ -29,7 +29,10 @@ public function createFrom($properties)
*/
public function withValue($value)
{
Type::enforce($value, Type::STRING);
Type::enforce($value, [
Type::STRING,
Type::INTEGER,
]);
$this->value = $value;

return $this;
Expand Down

0 comments on commit 6e6c163

Please sign in to comment.