Fix check to make sure map is not in a layer already