cleans up the media folder upon photo deletion