regions.set(r.ID, region);
The problem is regions are being added to the engine's list of regions twice.