fixed not calling hideLayers