Added PDF support. #2

merged 2 commits into from Sep 28, 2012

2 participants


FreshBooks added the invoice.getPDF command, which returns binary PDF data instead of XML. I changed the library to handle the case when PDF data is sent from FreshBooks and will handle it accordingly.


Thanks for doing this. Can you please adjust the code to follow the same standard as the file. Example 4 spaces for indentation, curly braces on new line for if/else.

@jboesch jboesch commented on an outdated diff Sep 28, 2012
@@ -145,7 +145,7 @@ public function getGeneratedXML()
* Send the request over the wire
- * @return array
+ * @return binary data if response is a PDF, array if not

Alright, good to go. Let me know if there's any other tweaks that should be done.

@jboesch jboesch merged commit b8d58a9 into jboesch:master Sep 28, 2012

Looks great! Thank you for doing this :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment