Skip to content

Discount Code creation failed #7011

@iamareebjamal

Description

@iamareebjamal

After merging of #6985, discount code creation fails:

For some bizarre reason, user_id was passed in constructor of DiscountCode and then set to marketer_id 🤷‍♂️
Anyway it was still working because for another bizarre reason, marketer passed from the API was changed to user_id on server 🤷‍♂️ 🤷

So now, because the constructor is removed, there is no user_id kwarg in Discount Code and it throws. The build didn't break because no dredd test was present for passing marketer ID. I am not sure why is it even needed, but add the test for now to ensure it doesn't break in future

Edit: It was present in Dredd tests but disabled in #4854

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions