Sha256: 2ae100118d1a12754997ac2e8db943519a0e08d905608569c275bf0d677553b2
Contents?: true
Size: 675 Bytes
Versions: 21
Compression:
Stored size: 675 Bytes
Contents
module Resourcelogic class FailableActionOptions extend Resourcelogic::Accessors scoping_reader :success, :fails alias_method :failure, :fails block_accessor :before def initialize @success = ActionOptions.new @fails = ActionOptions.new end delegate :flash, :flash_now, :after, :response, :wants, :to => :success def dup returning self.class.new do |duplicate| duplicate.instance_variable_set(:@success, success.dup) duplicate.instance_variable_set(:@fails, fails.dup) duplicate.instance_variable_set(:@before, before.dup) unless before.nil? end end end end
Version data entries
21 entries across 21 versions & 2 rubygems