lib/tap.rb in markdown_exec-2.3.0 vs lib/tap.rb in markdown_exec-2.4.0
- old
+ new
@@ -33,12 +33,10 @@
val.to_i
end
end
end
-# rubocop:disable Metrics/ParameterLists
-
## application-level debug control
#
# :reek:TooManyConstants
module Tap
include Env
@@ -96,20 +94,21 @@
self
end
# :reek:ControlParameter
# :reek:LongParameterList
- def tap_inspect(name_ = nil, caller_first: nil, mask: TDD, name: DN, source: nil,
- type: nil)
+ def tap_inspect(name_ = nil, caller_first: nil, mask: TDD, name: DN,
+ source: nil, type: nil)
return self unless $tap_enable
return self unless (mask & $tap_mask).positive?
fn = CVT.fetch(type, CVT[:else])
outs = []
outs.push(source.to_s) if source.present?
- vs = (caller_first || caller[0]).scan(/in `?(\S+)'$/).fetch(0, []).fetch(0, '')
+ vs = (caller_first || caller[0]).scan(/in `?(\S+)'$/)
+ .fetch(0, []).fetch(0, '')
outs.push("#{vs}()") if vs.present?
outs.push(tap_named_value(name_ || name, method(fn).call))
$stdout.puts(outs.join(' ')) if outs.length.positive?
@@ -141,10 +140,10 @@
end
# :reek:ControlParameter
# :reek:LongParameterList
def tap_yaml(name_ = nil, caller_first: nil, mask: TDD, name: DN, source: nil)
- tap_inspect name_, caller_first: (caller_first || caller[0]),
+ tap_inspect name_, caller_first: caller_first || caller[0],
mask: mask, name: name, source: source, type: :yaml
end
private