Fixed an issue when snappedLayer was not cleaned after drawing has stopped