Class: Clacky::ApiExtension::ScopedLogger

Inherits:
Object
  • Object
show all
Defined in:
lib/clacky/api_extension.rb

Overview

Lightweight wrapper that prefixes log lines with the extension id.

Instance Method Summary collapse

Constructor Details

#initialize(ext_id) ⇒ ScopedLogger

Returns a new instance of ScopedLogger.



251
252
253
# File 'lib/clacky/api_extension.rb', line 251

def initialize(ext_id)
  @prefix = "[api_ext:#{ext_id}]"
end