I’m doing some route hacking and have run into something I haven’t
been able to get past. I need to add a custom condition on to RESTful
resources in the same way that you can add custom conditions to other
routes. I have already hacked on my solution for most routes by
chaining to recognition_conditions, but the conditions seem to be
ignored by RESTful routes.
The desired behavior would be to pass a :conditions => {:subdomain =>
true/false} and have that run a logic check to see whether the
subdomain of the current host matches against a list of allowed
subdomains. I have the logic, it works fine for most routes, but I
can’t see how to add conditions to the RESTful routes since they
aren’t picked up by the rest.
Any help would be appreciated.
Thanks,
Michael B.