From 7a3f2dcf5ad7596d0b4cba0ec5f8e30bc23d4444 Mon Sep 17 00:00:00 2001 From: AlgorithmX2 Date: Tue, 20 May 2014 09:37:53 -0500 Subject: [PATCH] Don't call Grid cache updates if the grid is empty. --- me/Grid.java | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/me/Grid.java b/me/Grid.java index b3da1d9cd..2a6065a7b 100644 --- a/me/Grid.java +++ b/me/Grid.java @@ -199,9 +199,13 @@ public class Grid implements IGrid public void update() { - for (IGridCache gc : caches.values()) + // are ther any nodes left? + if ( pivot != null ) { - gc.onUpdateTick(); + for (IGridCache gc : caches.values()) + { + gc.onUpdateTick(); + } } }