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

Allow fallback to specify what methods it will catch #1149

Open
UnsolvedCypher opened this issue May 19, 2020 · 1 comment
Open

Allow fallback to specify what methods it will catch #1149

UnsolvedCypher opened this issue May 19, 2020 · 1 comment
Labels
feature request A new requested feature / option

Comments

@UnsolvedCypher
Copy link
Contributor

Currently, fallback only catches GET requests, but I think it would be helpful to optionally specify an array of methods that it will catch. The use case would be to delegate certain requests to another server (for example, have Lucky catch POST requests to a certain subdirectory and make them to a third-party API or another server running locally).

@paulcsmith paulcsmith added the feature request A new requested feature / option label May 20, 2020
@paulcsmith
Copy link
Member

I think your idea of an array of methods is a great idea. The default can be get but overridable:

fallback(:get, :post, :put)

Thanks for the suggestion and feature request

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature request A new requested feature / option
Projects
None yet
Development

No branches or pull requests

2 participants