Module: CopycopterClient::Rails

Defined in:
lib/copycopter_client/rails.rb

Overview

Responsible for Rails initialization

Class Method Summary collapse

Class Method Details

.initializeObject

Sets up the logger, environment, name, project root, and framework name for Rails applications. Must be called after framework initialization.



6
7
8
9
10
11
12
13
# File 'lib/copycopter_client/rails.rb', line 6

def self.initialize
  CopycopterClient.configure(false) do |config|
    config.environment_name = ::Rails.env
    config.logger           = ::Rails.logger
    config.framework        = "Rails: #{::Rails::VERSION::STRING}"
    config.middleware       = ::Rails.configuration.middleware
  end
end