-
-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
add array support for metadata, fixes #4 #6
Conversation
I fixed the phpstan errors, except for one: vendor/bin/phpstan
final class Metadata
{
public function __construct(
/** @readonly */
public string $key,
/**
* @readonly
* @param string|bool|int|float|mixed value
*/
public string|bool|int|float|array $value,
) {
} What should this be? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good! I think my suggestions will fix phpstan.
It got me thinking, though, if null should be allowed as a valid metadata value.
Couldn't hurt but maybe wait until someone needs it.
Co-authored-by: Kevin Bond <[email protected]>
Co-authored-by: Kevin Bond <[email protected]>
Co-authored-by: Kevin Bond <[email protected]>
Co-authored-by: Kevin Bond <[email protected]>
I'll take a look at fixing phpstan before merging. |
Thanks @tacman! |
I updated the docs, attribute and tests.
It got me thinking, though, if null should be allowed as a valid metadata value.
Nonetheless, I think this fixes #4