Corrected  PDF gen error