fix pdf generation #30