You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Right now, if you want to handle exceptions, your choices are to thread through a block to every single function call, or to do weird import gymnastics to get at the hidden codegen modules.
If the various ApiError types all subclassed from a single public exception (something like Hubspot::BaseException), it'd be much more straightforward to use normal Ruby exception handling.
What I'm doing for now is basically
begin# do lots of hubspot stuffrescue=>excraiseexcunlessexc.class.name.match?(/\AHubspot::.*ApiError\z/)# handle hubspot exceptionsend
The text was updated successfully, but these errors were encountered:
Right now, if you want to handle exceptions, your choices are to thread through a block to every single function call, or to do weird import gymnastics to get at the hidden
codegen
modules.If the various
ApiError
types all subclassed from a single public exception (something likeHubspot::BaseException
), it'd be much more straightforward to use normal Ruby exception handling.What I'm doing for now is basically
The text was updated successfully, but these errors were encountered: