From de3e9049b3838b3dc5f5ad83402ee224ede8db8c Mon Sep 17 00:00:00 2001 From: Martin Edenhofer Date: Wed, 9 Sep 2015 14:31:31 +0200 Subject: [PATCH] Improved error handling. --- lib/stats/ticket_load_measure.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/stats/ticket_load_measure.rb b/lib/stats/ticket_load_measure.rb index c223ebdc4..1c3e0fecb 100644 --- a/lib/stats/ticket_load_measure.rb +++ b/lib/stats/ticket_load_measure.rb @@ -37,7 +37,7 @@ class Stats::TicketLoadMeasure return result if !result.key?(:used_for_average) - if result[:total] < 1 + if result[:total] < 1 || result[:average_per_agent] == 0.0 result[:state] = 'supergood' return result end