Rails 4 route mapper compatibility #24

Merged
merged 2 commits into from Jan 9, 2013

Projects

None yet

4 participants

@jamesotron
Owner

This is great. Do we need to match against the other HTTP verbs though?

@nilbus
Collaborator
nilbus commented Jan 9, 2013

I was wondering that - what do you think? I can't imagine using other verbs to connect from a client, but I figured you would know better. Technically to maintain full backward compatibility, it should include all verbs. How far do you take it? I'm open to your thoughts on this though.

@nilbus
Collaborator
nilbus commented Jan 9, 2013

On second glance at the Rails 4 code, it looks like you can use match ..., via: :all. And given that post, I think we should. I'll test and modify the pull request.

@jamesotron
Owner

Cool, thanks!

@nilbus
Collaborator
nilbus commented Jan 9, 2013

This works with Rails 4 and matches all HTTP verbs like before. Good catch!

@jamesotron jamesotron merged commit 7263922 into jamesotron:master Jan 9, 2013

1 check passed

default The Travis build passed
Details
@jamesotron
Owner

Thanks for the PR.

@nilbus
Collaborator
nilbus commented Jan 9, 2013

And you for the quick merge! I'll let you know if I hit any other issues with Rails 4 compatibility.

@jamesotron jamesotron added a commit that referenced this pull request Feb 5, 2013
@jamesotron Revert routing changes for Rails 4 compatibility, this has broken the…
… current release. Reopens #24.
e6f1c12
@aratak
aratak commented Mar 11, 2013

Guys, am I correctly understand that via: :all doesn't work with old rails?
In such event can we use via: [:get, :post]?

@jamesotron
Owner

This is something we're going to have to fix soon anyway, since we're so close to a Rails 4 release. We're going to need to increase the test coverage a bit so that we can prove that it works on Rails 3.x and Rails 4.

@aaronjensen
Collaborator

This should be reopened, yea?

@nilbus
Collaborator
nilbus commented Apr 28, 2013

Yes

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment