kevinohara80/nforce — pull request #17 by jneander (2013-05-10 19:42:25+00:00)
Title: Protecting against JSON parse errors in some methods

Previously, some functions assumed that all responses coming from SalesForce had valid JSON in the bodies. This caused unrecoverable errors in production. Parsing of the JSON in this function is now handled safely and will return with an error and the original body in the event that the JSON is invalid.

For the most part, only functions touched by production code were updated. Significant code duplication indicates that there are functions with too much responsibility. Those can/will be addressed in subsequent changes.