Sha256: d61a7583cd1f0ba83601a0d21717ceb9ba941f94c97e053d29be6decb6d60414

Contents?: true

Size: 262 Bytes

Versions: 3

Compression:

Stored size: 262 Bytes

Contents

# frozen_string_literal: true

module Articles
  class EditAction < UserAction
    expose :article

    def perform(id)
      @article = ArticleRepository.new.find_for_user(id, user: @current_user)
      raise UnauthorizedError unless @article
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
upgrow-0.0.5 test/dummy/app/actions/articles/edit_action.rb
upgrow-0.0.4 test/dummy/app/actions/articles/edit_action.rb
upgrow-0.0.3 test/dummy/app/actions/articles/edit_action.rb