Catches formatting errors in single place.
Adds short-circuit error returns.
Merge pull request #57 from nisaacson/format-try-catch

Format try catch