mirror of
https://github.com/standardebooks/web.git
synced 2025-07-15 10:56:46 -04:00
Fix PHPStan errors for CollectionType enum
Use the `value` property of PHP enums to get the underlying string for functions that expect a string. Followup to #392
This commit is contained in:
parent
b792dec9e5
commit
9a4da8f961
3 changed files with 4 additions and 4 deletions
|
@ -60,7 +60,7 @@ class Collection{
|
|||
}
|
||||
|
||||
if($this->Type !== null && ($this->Type != CollectionType::Series && $this->Type != CollectionType::Set)){
|
||||
$error->Add(new Exceptions\InvalidCollectionTypeException($this->Type));
|
||||
$error->Add(new Exceptions\InvalidCollectionTypeException($this->Type->value));
|
||||
}
|
||||
|
||||
if($error->HasExceptions){
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue