Fixed end url backslash problem that caused 404.
mapbox code styling. Cleaned depreciated functions.