lib/remnant/base.rb in remnant-0.3.2 vs lib/remnant/base.rb in remnant-0.3.3
- old
+ new
@@ -40,11 +40,11 @@
Remnant::Discover.results.map do |remnant_key, ms|
Remnant.handler.timing("#{key_prefix}.#{remnant_key}", ms.to_i)
end
if Remnant::Database.enabled?
- Remnant.handler.timing("#{key_prefix}.db", Remnant::Database.queries.total_time.to_i)
+ Remnant.handler.timing("#{key_prefix}.db", Remnant::Database.total_time.to_i)
end
@sample_counter = 0
else
@sample_counter += 1
@@ -70,10 +70,10 @@
end
end
if Remnant::Database.enabled?
Rails.logger.info ""
- Rails.logger.info("#{color(false, true)}---- Database (%.2fms) -----#{color(true)}" % Remnant::Database.queries.total_time)
+ Rails.logger.info("#{color(false, true)}---- Database (%.2fms) -----#{color(true)}" % Remnant::Database.total_time)
if Remnant::Database.suppress?
Rails.logger.info "queries suppressed in development mode"
else
Remnant::Database.queries.map do |query|
Rails.logger.info("#{color}%.2fms#{color(true)}\t#{query.sql}" % (query.time * 1000))