Danack / Params

Framework agnostic validation
MIT License
6 stars 1 forks source link

GetArrayOfType only works on things that return InputParameterList #14

Open Danack opened 2 years ago

Danack commented 2 years ago

This seems like a sensible thing to want to do:

class AdvancedDTO
{
    use InputParameterListFromAttributes;

    public function __construct(
        #[MultipleColors('colors')]
        public array $colors,
        #[Quantity('quantity')]
        public float $quantity,
    ) {
    }
}

but as colors is only a param, and not a param list, it doesn't work.