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

Missing support for [PATCH, LINK, UNLINK] HTTP verbs. #1180

Closed
kenkeiter opened this issue Mar 25, 2013 · 0 comments · Fixed by #1181
Closed

Missing support for [PATCH, LINK, UNLINK] HTTP verbs. #1180

kenkeiter opened this issue Mar 25, 2013 · 0 comments · Fixed by #1181

Comments

@kenkeiter
Copy link

The http_router gem does not support the PATCH, LINK, and UNLINK HTTP verbs; as a result, Padrino doesn't support them, either. Defining routes with any of the following methods raises an error:

patch :index do; end
link :index do; end
unlink :index do; end

This monkey patch resolves the issue, but it's definitely a bad way to handle it.

HttpRouter::Route.send(:remove_const, :VALID_HTTP_VERBS)
HttpRouter::Route.send(:const_set, :VALID_HTTP_VERBS, %w{GET POST PUT PATCH DELETE HEAD OPTIONS TRACE LINK UNLINK})
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 a pull request may close this issue.

1 participant