Skip to content
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

NEXT-0000 - Improve write exception message to include property, that has faulty content #3722

Closed
wants to merge 1 commit into from

Conversation

JoshuaBehrens
Copy link
Contributor

1. Why is this change necessary?

When you do a bad API request, you do not understand why it is bad.

2. What does this change do, exactly?

Add the field name to the path mentioned in the exception.

3. Describe each step to reproduce the issue or behaviour.

  1. Use the API and create data
  2. Send request:
POST /api/seo-url-template
Content-Type: application/json
Accept: application/json

{
    "id": "118f8e56b0da7d81a4392f876b3b5ee6",
    "salesChannel": "foo",
    "entityName": "product",
    "routeName": "foobar",
    "template": "foo"
}
  1. Get error response with message Expected data at /0 to be an array
  2. Mike sully being confused, annoyed, feeling Weltschmerz

4. Checklist

  • I have rebased my changes to remove merge conflicts
  • I have written tests and verified that they fail without my change
  • I have created a changelog file with all necessary information about my changes
  • I have written or adjusted the documentation according to my changes
  • This change has comments for package types, values, functions, and non-obvious lines of code
  • I have read the contribution requirements and fulfil them.

@shopware-github-importer
Copy link

Hello,

thank you for creating this pull request.
I have opened an issue on our Issue Tracker for you. See the issue link: https://issues.shopware.com/issues/NEXT-36325

Please use this issue to track the state of your pull request.

@keulinho
Copy link
Contributor

Hey @JoshuaBehrens thanks for your contribution! Your PR just got merged 🎉 💙

@JoshuaBehrens
Copy link
Contributor Author

Thank you for merging :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants