lib/rom/changeset/pipe.rb in rom-changeset-1.0.0.rc1 vs lib/rom/changeset/pipe.rb in rom-changeset-1.0.0.rc2
- old
+ new
@@ -27,11 +27,11 @@
# @api private
class Pipe < Transproc::Transformer[PipeRegistry]
extend Initializer
param :processor, default: -> { self.class.transproc }
- option :diff_processor, optional: true
option :use_for_diff, optional: true, default: -> { true }
+ option :diff_processor, default: -> { use_for_diff ? processor : nil }
def self.[](name)
container[name]
end