Module: Decidim::AnonymousProposals::PublishProposalCommandOverrides
- Extended by:
- ActiveSupport::Concern
- Defined in:
- app/commands/decidim/anonymous_proposals/publish_proposal_command_overrides.rb
Overview
Method overrides to avoid errors when current_user is not present
Instance Method Summary collapse
Instance Method Details
#initialize(proposal, current_user) ⇒ Object
9 10 11 12 13 |
# File 'app/commands/decidim/anonymous_proposals/publish_proposal_command_overrides.rb', line 9 def initialize(proposal, current_user) @proposal = proposal @current_user = current_user @current_user ||= anonymous_group if allow_anonymous_proposals? end |