var oldCameraIcon = L.icon({ iconUrl: '/img/camera-0.png', iconSize: [30, 30], // size of the icon iconAnchor: [15, 15], // point of the icon which will correspond to marker's location popupAnchor: [0, -10] // point from which the popup should open relative to the iconAnchor }); var newCameraIcon = L.icon({ iconUrl: '/img/camera-1.png', iconSize: [30, 30], // size of the icon iconAnchor: [15, 15], // point of the icon which will correspond to marker's location popupAnchor: [0, -10] // point from which the popup should open relative to the iconAnchor });