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

redirect with 303 so as not to carry :DELETE method #1

Merged
merged 1 commit into from
Jun 8, 2014
Merged

Conversation

nathanscott
Copy link
Member

The 302 redirect causes the HTML method to be preserved and carried across. So when redirecting from the index, when unliking it will push the user back to the destroy action.

Added 303 to redirect to prevent the method sticking.

I know all of this is customisable, it's just not the best default behaviour. Results in deleting objects when unliking.

pat added a commit that referenced this pull request Jun 8, 2014
redirect with 303 so as not to carry :DELETE method
@pat pat merged commit 37831cc into master Jun 8, 2014
@pat
Copy link
Collaborator

pat commented Jun 8, 2014

I think something's been added to the HTTP spec just in the last few days about this - but yeah, 303 sounds like the smart approach here.

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.

2 participants