Fixed CSV download process