From 6f3b59afef6d71bd823d0aa56a7f1b35b35b6c0e Mon Sep 17 00:00:00 2001 From: Amos Benari Date: Sun, 13 Nov 2011 10:45:11 +0200 Subject: [PATCH] Changed reported_at to created_at to solve a bug caused by a host reporting the time incorrectly. --- app/models/host.rb | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/app/models/host.rb b/app/models/host.rb index b9ddfb6..9fdde28 100644 --- a/app/models/host.rb +++ b/app/models/host.rb @@ -512,8 +512,8 @@ class Host < Puppet::Rails::Host data = {} data[:config], data[:runtime] = [], [] reports.recent(timerange).each do |r| - data[:config] << [r.reported_at.to_i*1000, r.config_retrieval] - data[:runtime] << [r.reported_at.to_i*1000, r.runtime] + data[:config] << [r.created_at.to_i*1000, r.config_retrieval] + data[:runtime] << [r.created_at.to_i*1000, r.runtime] end return data end -- 1.7.4.2