Files
nairobi/app/components/admin/poll/questions/form_component.rb
Javi Martín 4c8be42ea1 Simplify new question form
In this form, the only case where `poll` might be present without
`question.poll` being present to is going to be the `new` action. We can
assign the poll in the `new` action and get rid of the `poll` variable
in the form.
2022-09-20 17:29:04 +02:00

11 lines
240 B
Ruby

class Admin::Poll::Questions::FormComponent < ApplicationComponent
include TranslatableFormHelper
include GlobalizeHelper
attr_reader :question, :url
def initialize(question, url:)
@question = question
@url = url
end
end