Module: DeprecationToolkit::WarningPatch

Defined in:
lib/deprecation_toolkit/warning.rb

Instance Method Summary collapse

Instance Method Details

#warn(str) ⇒ Object



55
56
57
58
59
60
61
62
63
64
# File 'lib/deprecation_toolkit/warning.rb', line 55

def warn(str, *)
  str = DeprecationToolkit::Warning.handle_multipart(str)
  return unless str

  if DeprecationToolkit::Warning.deprecation_triggered?(str)
    DeprecationToolkit::Warning.deprecator.warn(str)
  else
    super
  end
end