meteor-pdfkit
meteor-pdfkit copied to clipboard
Question: get a return of writeSync()
Hi there! Thanks for the nice package - works like a charm! :-) Since you provide a sync function which write the file (writeSync) I wonder - why is there no return value of this function? How can I know if creating and writing the pdf file was successful so I can move on in my code (in my case: send the pdf via e-mail)?
var write = doc.writeSync(process.env.PWD + '/public/pdf/' + orderid + '_order.pdf');
console.log('writefile return: ' + write);
Writing the file works just fine but write is always undefined.
I think we have to change the package code to fix this. As I'm realy busy right now I will see if someone make a PR. If not I will.
Thanks for reporting @Twisterking :).