moved the methods dealing with csv export closer together
security update