Fix saveAsPDF case in Gantt API