Title: [opsview] [9601] initally set unhandled to "ok"
Revision
9601
Author
aburzynski
Date
2012-07-20 16:49:25 +0100 (Fri, 20 Jul 2012)

Log Message

initally set unhandled to "ok"

Modified Paths


Modified: trunk/opsview-core/lib/Runtime/ResultSet.pm
===================================================================
--- trunk/opsview-core/lib/Runtime/ResultSet.pm	2012-07-20 15:47:23 UTC (rev 9600)
+++ trunk/opsview-core/lib/Runtime/ResultSet.pm	2012-07-20 15:49:25 UTC (rev 9601)
@@ -219,9 +219,9 @@
     my $last_group_key   = "";
     my $last_hash;
     my $found_hosts;
-    my $highest_host_unhandled_state;
-    my $highest_service_unhandled_state;
-    my $uses_exclude_handled = 0;
+    my $highest_host_unhandled_state    = 0;
+    my $highest_service_unhandled_state = 0;
+    my $uses_exclude_handled            = 0;
     my $status;
     my $summary = {
         host => {
@@ -303,22 +303,15 @@
                 },
                 downtime => $downtimes->{ $hash->{$group_key} }->{state},
             };
-            $found_hosts      = {};
-            $last_group_label = $hash->{$group_label};
-            $last_group_key   = $hash->{$group_key};
-            $last_hash        = $hash;
-            undef $highest_host_unhandled_state;
-            undef $highest_service_unhandled_state;
-            $uses_exclude_handled = 0;
+            $found_hosts                     = {};
+            $last_group_label                = $hash->{$group_label};
+            $last_group_key                  = $hash->{$group_key};
+            $last_hash                       = $hash;
+            $highest_host_unhandled_state    = 0;
+            $highest_service_unhandled_state = 0;
+            $uses_exclude_handled            = 0;
         }
 
-        unless ( defined $highest_host_unhandled_state ) {
-            $highest_host_unhandled_state = $hash->{host_state};
-        }
-        unless ( defined $highest_service_unhandled_state ) {
-            $highest_service_unhandled_state = $hash->{service_state};
-        }
-
         $uses_exclude_handled = $hash->{exclude_handled};
 
         if ( $args->{viewport_check_exclude_handled} && $uses_exclude_handled )

_______________________________________________
Opsview-checkins mailing list
[email protected]
http://lists.opsview.org/lists/listinfo/opsview-checkins

Reply via email to