change to layerList and some code clean
changes in layerList