Removing (now) superfluous rebuildLayers() calls - keeping the one in the unit tests so we can verify that it works properly