clean log
This commit is contained in:
@@ -126,7 +126,6 @@ Rails.application.configure do
|
||||
config.lograge.enabled = true
|
||||
config.lograge.base_controller_class = ['ActionController::API', 'ActionController::Base']
|
||||
|
||||
if ENV['MULTITENANT'] == 'true'
|
||||
config.lograge.formatter = ->(data) { data.except(:path, :location).to_json }
|
||||
|
||||
config.lograge.custom_payload do |controller|
|
||||
@@ -149,19 +148,10 @@ Rails.application.configure do
|
||||
params[:submitter_slug] ||
|
||||
params[:submission_slug] ||
|
||||
params[:submit_form_slug] ||
|
||||
params[:template_slug]).to_s.last(5)
|
||||
params[:template_slug]).to_s.first(5)
|
||||
}.compact_blank,
|
||||
host: controller.request.host,
|
||||
uid: controller.instance_variable_get(:@current_user).try(:id)
|
||||
}
|
||||
end
|
||||
else
|
||||
config.lograge.formatter = Lograge::Formatters::Json.new
|
||||
|
||||
config.lograge.custom_payload do |controller|
|
||||
{
|
||||
fwd: controller.request.remote_ip
|
||||
}
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user