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

Fix undefined variable middleware #151

Conversation

bastien-phi
Copy link
Collaborator

I fucked up with git, original PR (#137) was closed 🤦

This PR fixes #136

Problem comes from the fact that in the test suite, we are using Laravel's exception handler wich will hide some issues. If in their projet the developer uses withoutExceptionHandling, they can face Spectator bug (in this case returning an undefined variable).

I decided to fix this issue extracting PathItem resolution from actual request/response validation.

I would also suggest to run the entire test suite without exception handling (except required ones like ValidationException or HttpException) in order to prevent such issues to be hidden again. I can send a follow-up PR if you want.

Finally, not sur if this PR should be sent to master or develop branch. @hotmeteor please tell me if I should send it to develop, I will rebase my branch and change that

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

Successfully merging this pull request may close these issues.

ErrorException: Undefined variable $response in Middleware.php
1 participant