adrien2p / medusa-extender

:syringe: Medusa on steroid, take your medusa project to the next level with some badass features :rocket:
https://adrien2p.github.io/medusa-extender/
MIT License
321 stars 39 forks source link

[BUG] Extending Product Validator not working #141

Closed parliament718 closed 2 years ago

parliament718 commented 2 years ago

Package version:

Screen Shot 2022-10-26 at 12 14 28 PM Screen Shot 2022-10-26 at 12 14 33 PM

Screen Shot 2022-10-26 at 12 36 21 PM Screen Shot 2022-10-26 at 12 36 28 PM Screen Shot 2022-10-26 at 12 36 37 PM Screen Shot 2022-10-26 at 12 36 45 PM

Am I missing some piece?

parliament718 commented 2 years ago

Screen Shot 2022-10-28 at 8 52 39 AM

Validator seems to be applied on run . Additionally I have changed back the ProductEntity class name to Product as it seemed to be causing an issue.

What could be going wrong then?

parliament718 commented 2 years ago

Figured it out. I needed to create a validator for both

AdminPostProductsReq (create product) and AdminPostProductsProductReq (update product)