changed the code for shp file