Sha256: 4642631e676804090bee69dcc3ab42f3a89c3e0bacabb647bf923f70d6d4254d

Contents?: true

Size: 391 Bytes

Versions: 7

Compression:

Stored size: 391 Bytes

Contents

# frozen_string_literal: true
module Thredded
  # @api private
  module NewTopicParams
    protected

    def new_topic_params
      params
        .fetch(:topic, {})
        .permit(:title, :locked, :sticky, :content, category_ids: [])
        .merge(
          messageboard: messageboard,
          user: thredded_current_user,
          ip: request.remote_ip,
        )
    end
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
thredded-0.12.1 app/controllers/concerns/thredded/new_topic_params.rb
thredded-0.12.0 app/controllers/concerns/thredded/new_topic_params.rb
thredded-0.11.1 app/controllers/concerns/thredded/new_topic_params.rb
thredded-0.11.0 app/controllers/concerns/thredded/new_topic_params.rb
thredded-0.10.1 app/controllers/concerns/thredded/new_topic_params.rb
thredded-0.10.0 app/controllers/concerns/thredded/new_topic_params.rb
thredded-0.9.4 app/controllers/concerns/thredded/new_topic_params.rb