Module: LightService::Deprecation
- Defined in:
- lib/light-service/deprecation_warning.rb
Class Method Summary collapse
-
.warn(message, callstack = caller) ⇒ Object
:nocov: Basic implementation of a deprecation warning.
Class Method Details
.warn(message, callstack = caller) ⇒ Object
:nocov: Basic implementation of a deprecation warning
6 7 8 9 10 11 12 13 14 15 |
# File 'lib/light-service/deprecation_warning.rb', line 6 def warn(, callstack = caller) # Construct the warning message = "DEPRECATION WARNING: #{message}\n" += "Called from: #{callstack.first}\n" unless callstack.empty? # Output the warning message to stderr or a log file warn # Additional logging or actions can be added here end |