Build a booking app in less than an hour...
# avo-2
b
Hello, I'm running the bookr demo application (

https://www.youtube.com/watch?v=BK47E7TMXn0

) and am facing an issue: any time I use an action (i.e., in the demo, "Delay booking"), the action completes successfully but I have an ugly error message in my logs:
Copy code
Unpermitted parameter: :button. Context: { controller: Avo::ActionsController, action: handle, request: #<ActionDispatch::Request:0x00007fb03cbae4f8>, params: {"authenticity_token"=>"[FILTERED]", "action_id"=>"DelayBooking", "fields"=>{"avo_resource_ids"=>"1", "avo_selected_query"=>"", "number_of_hours"=>"1"}, "button"=>"", "controller"=>"avo/actions", "action"=>"handle", "resource_name"=>"bookings"} }
Unpermitted parameter: :button. Context: { controller: Avo::ActionsController, action: handle, request: #<ActionDispatch::Request:0x00007fb03cbae4f8>, params: {"authenticity_token"=>"[FILTERED]", "action_id"=>"DelayBooking", "fields"=>{"avo_resource_ids"=>"1", "avo_selected_query"=>"", "number_of_hours"=>"1"}, "button"=>"", "controller"=>"avo/actions", "action"=>"handle", "resource_name"=>"bookings"} }
Unpermitted parameter: :button. Context: { controller: Avo::ActionsController, action: handle, request: #<ActionDispatch::Request:0x00007fb03cbae4f8>, params: {"authenticity_token"=>"[FILTERED]", "action_id"=>"DelayBooking", "fields"=>{"avo_resource_ids"=>"1", "avo_selected_query"=>"", "number_of_hours"=>"1"}, "button"=>"", "controller"=>"avo/actions", "action"=>"handle", "resource_name"=>"bookings"} }
Is this happening only to me (Ubuntu 22.04 with Avo 2.33.1)?
l
hmm, yes, it's an error that the button param is not permitted
is that an issue? it's not raising an error, right?
b
Well, it is not an issue in the sense that the action is processing successfully, but there is obviously something wrong somewhere to throw such log 3 times.
l
yeah, we're probably doing
params.permit
more than one time. we could cache it
I'll try to have a look. we're open to a PR if you'd like to have a look sooner
11 Views