PHOENIX-2696 Delete stale stats for a region if in later run no guidePosts found for that region(addendum)
diff --git a/phoenix-core/src/main/java/org/apache/phoenix/schema/stats/DefaultStatisticsCollector.java b/phoenix-core/src/main/java/org/apache/phoenix/schema/stats/DefaultStatisticsCollector.java
index c56c102..adce23c 100644
--- a/phoenix-core/src/main/java/org/apache/phoenix/schema/stats/DefaultStatisticsCollector.java
+++ b/phoenix-core/src/main/java/org/apache/phoenix/schema/stats/DefaultStatisticsCollector.java
@@ -128,8 +128,8 @@
             // This will not impact a stats collection of single column family during compaction as
             // guidePostsInfoWriterMap cannot be empty in this case.
             if (guidePostsInfoWriterMap.keySet().isEmpty()) {
-                for (Store store : region.getStores()) {
-                    statsTable.deleteStats(region, this, new ImmutableBytesPtr(store.getFamily().getName()), mutations);
+                for (byte[] fam : region.getStores().keySet()) {
+                    statsTable.deleteStats(region, this, new ImmutableBytesPtr(fam), mutations);
                 }
             }
             for (ImmutableBytesPtr fam : guidePostsInfoWriterMap.keySet()) {