adding a helper for try/catch blocks