-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
Using mounted method within params #2321
Comments
I don't think you're missing anything. Try adding it to |
Hi @dblock , thanks for answering, as far as I can see, the code is as the documentation specifies, specifically: https://github.com/ruby-grape/grape#mount-configuration , I should be able to do this without modifying the gem, right? |
Ah I see. Yes, that would be a bug. Care to add a (failing) test? |
Hi - this is my bad as clearly I got overly eager on the docs. We can fix it in one of two ways: First just update the docs. The behaviour described on those docs is achievable without the Alternatively: Define the Added this PR: #2339 |
Closed via #2339 |
When constructing a namespace, where options are passed through the
configuration
hashIn order to declare the params using the entity set in the configuration, as per the documentation:
Results in:
The
mounted
method, does seem to be accessible via the@api
variable withinGrape::Validations::ParamsScope
Maybe I am missing something?
In any case, thanks in advance for taking a look
Here the full backtrace or the Error:
Here the rest of the relevant code
The text was updated successfully, but these errors were encountered: