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

protect post routes with middleware #139

Merged
merged 6 commits into from
Sep 25, 2019
Merged

protect post routes with middleware #139

merged 6 commits into from
Sep 25, 2019

Conversation

Gummibeer
Copy link
Contributor

@Gummibeer Gummibeer commented Sep 12, 2019

Like discussed with @freekmurze this adds a little protection to the two post routes. In extension of #93

Copy link
Collaborator

@freekmurze freekmurze left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you also add a tests for the middleware?

src/Http/Middleware/IgnitionRunnableSolutionsEnabled.php Outdated Show resolved Hide resolved
src/Http/Middleware/IgnitionRunnableSolutionsEnabled.php Outdated Show resolved Hide resolved
src/Http/Middleware/IgnitionShareEnabled.php Outdated Show resolved Hide resolved
@freekmurze
Copy link
Collaborator

Thanks for your work on this 👍

@freekmurze
Copy link
Collaborator

Only thing missing here seems to be a test, could you add that @Gummibeer ?

@Gummibeer
Copy link
Contributor Author

Unit or feature?

@freekmurze
Copy link
Collaborator

Depends what you understand under those terms. I would have a test that sets up a route with the middleware applied to it.

The test would test just make calls to that route.

@Gummibeer
Copy link
Contributor Author

Ok, so feature/implementation. Unittest, for me, would be calling the middleware handle method directly and expect any result.
Will do it tomorrow.

@freekmurze
Copy link
Collaborator

👍

@Gummibeer
Copy link
Contributor Author

unittests added in c5ded3e

@freekmurze
Copy link
Collaborator

Thanks for your work on this.

@mpociot if you agree with these changes too, we can merge them.

@mpociot mpociot merged commit 1d854bc into facade:master Sep 25, 2019
@mpociot
Copy link
Contributor

mpociot commented Sep 25, 2019

Thank you for this! :)

@Gummibeer Gummibeer deleted the ft-protect-post-routes branch September 25, 2019 11:10
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.

3 participants