attempt to fix the pdf gen